Post #100 102!

January 3rd, 2009

After just over two and a half years of writing The Math Less Traveled, I’ve reached 100 posts! (Well, 102 actually, I seem to have missed 100…) It’s a little hard to believe I’ve actually written that much, and kept this little project going for so long. Thanks for reading! And I know I haven’t written anything in a while—grad school and such—but look for some more nifty math coming soon!

Sine of an inscribed angle

December 6th, 2008

Did you know that the ratio between the side of any triangle and the sine of the opposite angle is equal to the diameter of the triangle’s circumcircle? I didn’t! I just learned it today when researching the law of sines. All that time spent on the law of sines in high school, and no one ever bothered to tell me that in any triangle, not only are all the ratios between side lengths and sines of opposite angles equal to each other, they are also equal to something else interesting — namely, the diameter of the circumcircle!

Among other things, this means in particular that if you inscribe any angle in a circle with diameter one, the length of the chord it subtends is equal to the sine of the angle:


The sine of an angle inscribed in a unit circle is equal to the length of the subtended chord!

Nifty, eh? Want to see a proof? Here it is:


Proof of the law of sines

Rather than explain it in detail, I’ll just let you stare at it for a while, and leave a comment if you have questions. =) The one thing you need to remember from geometry that you might not remember is that an angle inscribed in a circle (like \theta in the above picture) subtends an angle twice as large.

Predicting Pi: solution

October 23rd, 2008

Now for the solution to the question in my previous post, which asked what you can learn about \pi, given the sequence of integers \floor{\pi}, \floor{2\pi}, \floor{3\pi}, \dots.

Nick Johnson commented:

Well, the obvious thing one can learn given just |(10^n)r| is the first n digits of the decimal expansion of r.

For example, when we are given \floor{100\pi} = 314, we can say with confidence that \pi \approx 3.14\dots. If we wait long enough, we can learn as many decimal digits of \pi as we want; in particular, to learn the first n decimal digits of \pi, we can just wait for the 10^nth item of the list.

This seems like an awfully long time to wait, though. Not only that, but if we only look at the first, tenth, hundredth, thousandth,… elements of the sequence, we would be ignoring almost all the information in the sequence! Intuitively, it seems that we should be able to do better by taking more of the sequence into account. And indeed, we can.

The key is to realize that


\floor{n\pi} \leq n\pi < \floor{n\pi} + 1.

Do you see why? Taking the floor of something never makes it bigger, so \floor{n\pi} \leq n\pi (in fact, it can never be equal since \pi is irrational, but that’s not important for our purposes). Also, taking the floor of something reduces it by some amount less than one, so adding one to the floor gives us something bigger than the original; hence n\pi < \floor{n\pi} + 1. Dividing through by n, we find that


 \displaystyle \frac{\floor{n\pi}}{n} \leq \pi < \frac{\floor{n\pi} + 1}{n}.

That is, if the nth element of the sequence is k, then we know that \pi must be between k/n and (k + 1)/n. Of course, this works for any number r, not just for \pi.

Let’s see how this works. The first few numbers in the sequence \floor{\pi}, \floor{2\pi}, \floor{3\pi}, \dots are 3, 6, 9, \dots. After seeing the 3, we know that 3/1 \leq \pi < 4/1. After seeing the 6, we know that 6/2 \leq \pi < 7/2 -- so we have a better upper bound now (3.5) than we did before (4). After seeing the 9, we know 9/3 \leq \pi < 10/3, and so on. Notice that our lower bound hasn't changed yet. That won't happen until we get to \floor{8\pi} = 25, when we learn that 25/8 \leq \pi < 26/8. So our new lower bound is 3.125. But the upper bound at this step, 26/8 = 3.25, is actually worse than the upper bound that we would have found on the previous step, namely 22/7 = 3.142857... So in general, the upper and lower bounds that we find in each step might not be better than all the previous ones; we can just keep the greatest lower bound and the least upper bound that we've seen so far.

So, how good are these bounds? I wrote a little program to compute the best upper and lower bounds for various points in the sequence. Here's a table showing the best lower and upper bounds at various points in the sequence, and the decimal digits they give us confidence about.

Term Best bounds \pi so far
10 \frac{25}{8} < \pi < \frac{22}{7} 3.1
100 \frac{311}{99} < \pi < \frac{22}{7} 3.14
1000 \frac{2818}{897} < \pi < \frac{355}{113} 3.1415
10000 \frac{31218}{9937} < \pi < \frac{355}{113} 3.141592
100000 \frac{208341}{66317} < \pi < \frac{312689}{99532} 3.141592653
1000000 \frac{3126535}{995207} < \pi < \frac{1146408}{364913} 3.1415926535

As you can see, this method does much better than the method of just looking at powers of ten! At n = one million, we already know ten decimal digits of pi; by looking just at the one millionth element of the sequence, we would only know six digits. It turns out that in general, it is the case (which I will not prove) that on average, we can get approximately twice as many decimal digits by finding best upper and lower bounds this way instead of just looking at powers of ten.

In a future post I hope to make a graph of these upper and lower bounds and talk a little bit more about what’s going on—it turns out to be pretty interesting stuff!

Predicting Pi

October 1st, 2008

Inspired by a recent post over at Foxmaths!, here’s an interesting challenge question for you to think about:

Suppose I give you the sequence of integers \floor{\pi}, \floor{2 \pi}, \floor{3 \pi}, and so on, where \floor{x} denotes the greatest integer less than or equal to x—in other words, it means to round down. So the first number in the sequence would be \floor{\pi} = 3, the next number would be \floor{2 \pi} = 6, and so on. Given this sequence, what can you learn about \pi (assuming that you didn’t already know anything about it)?

A more general question: given the sequence of integers \floor{k r} for k = 1,2,3…, what can you learn about r?

The answer has many interesting connections to the theory of irrational numbers and continued fractions.

Decimal expansion zoo

September 23rd, 2008

In a comment on a previous post about rational numbers and decimal expansions, Steve Gilberg noted:

I’ve been fascinated at how any multiple of 1/7 that’s not an integer repeats the same digits in decimal expression, only starting at different points in the sequence:

1/7 = .142857…
3/7 = .428571…
2/7 = .285714…
6/7 = .857142…
4/7 = .571428…
5/7 = .714285…

I’ve rearranged the order of the fractions to make the pattern obvious.

This is pretty cool indeed, and probably well-known to many. But there’s nothing particularly special about 7, other than the fact that it is small. In order to talk about the sorts of patterns we find in the expansions of rational numbers—and why—I’m going to start by having a special exhibit: the Decimal Expansion Zoo! Have a look around and see if you notice any patterns. I’ll follow the convention of enclosing repeating portions in [square brackets]. So, for example, 0.23[48] means 0.234848484848… and so on.

Some questions for you to think about while you wander about the zoo: what patterns do you notice? Which decimal expansions terminate, and which are repeating—and how does it relate to the denominator? How are the different cycles for a given denominator related to each other, and why? How are the lengths of the cycles for a given denominator related to the denominator itself? I’ll answer all these questions, and more, in an upcoming post!

1/2 = .5                              1/8 = .125
                                      3/8 = .375
1/3 = .[3]                            5/8 = .625
2/3 = .[6]                            7/8 = .875  

1/4 = .25                             1/9 = .[1]
3/4 = .75                             2/9 = .[2]
                                      3/9 = .[3]
1/5 = .2                              4/9 = .[4]
2/5 = .4                              5/9 = .[5]
3/5 = .6                              6/9 = .[6]
4/5 = .8                              7/9 = .[7]
                                      8/9 = .[8]
1/6 = .1[6]
5/6 = .8[3]                           1/10 = .1
                                      3/10 = .3
1/7 = .[142857]                       7/10 = .7
3/7 = .[428571]                       9/10 = .9
2/7 = .[285714]
6/7 = .[857142]                       1/12  = .08[3]
4/7 = .[571428]                       5/12  = .41[6]
5/7 = .[714285]                       7/12  = .58[3]
                                      11/12 = .91[6]
1/11  = .[09]
2/11  = .[18]                         1/13  = .[076923]
3/11  = .[27]                         10/13 = .[769230]
4/11  = .[36]                         9/13  = .[692307]
5/11  = .[45]                         12/13 = .[923076]
6/11  = .[54]                         3/13  = .[230769]
7/11  = .[63]                         4/13  = .[307692]
8/11  = .[72]                         2/13  = .[153846]
9/11  = .[81]                         7/13  = .[538461]
10/11 = .[90]                         5/13  = .[384615]
                                      11/13 = .[846153]
1/17  = .[0588235294117647]           6/13  = .[461538]
10/17 = .[5882352941176470]           8/13  = .[615384]
15/17 = .[8823529411764705]
14/17 = .[8235294117647058]           1/14  = .0[714285]
4/17  = .[2352941176470588]           3/14  = .2[142857]
6/17  = .[3529411764705882]           5/14  = .3[571428]
9/17  = .[5294117647058823]           9/14  = .6[428571]
5/17  = .[2941176470588235]           11/14 = .7[857142]
16/17 = .[9411764705882352]           13/14 = .9[285714]
7/17  = .[4117647058823529]
2/17  = .[1176470588235294]           1/15  = .0[6]
3/17  = .[1764705882352941]           2/15  = .1[3]
13/17 = .[7647058823529411]           4/15  = .2[6]
11/17 = .[6470588235294117]           7/15  = .4[6]
8/17  = .[4705882352941176]           8/15  = .5[3]
12/17 = .[7058823529411764]           11/15 = .7[3]
                                      13/15 = .8[6]
1/18  = .0[5]                         14/15 = .9[3]
5/18  = .2[7]
7/18  = .3[8]                         1/16  = .0625
11/18 = .6[1]                         3/16  = .1875
13/18 = .7[2]                         5/16  = .3125
17/18 = .9[4]                         7/16  = .4375
                                      9/16  = .5625
1/19  = .[052631578947368421]         11/16 = .6875
10/19 = .[526315789473684210]         13/16 = .8125
5/19  = .[263157894736842105]         15/16 = .9375
12/19 = .[631578947368421052]
6/19  = .[315789473684210526]         1/31  = .[032258064516129]
3/19  = .[157894736842105263]         10/31 = .[322580645161290]
11/19 = .[578947368421052631]         7/31  = .[225806451612903]
15/19 = .[789473684210526315]         8/31  = .[258064516129032]
17/19 = .[894736842105263157]         18/31 = .[580645161290322]
18/19 = .[947368421052631578]         25/31 = .[806451612903225]
9/19  = .[473684210526315789]         2/31  = .[064516129032258]
14/19 = .[736842105263157894]         20/31 = .[645161290322580]
7/19  = .[368421052631578947]         14/31 = .[451612903225806]
13/19 = .[684210526315789473]         16/31 = .[516129032258064]
16/19 = .[842105263157894736]         5/31  = .[161290322580645]
8/19  = .[421052631578947368]         19/31 = .[612903225806451]
4/19  = .[210526315789473684]         4/31  = .[129032258064516]
2/19  = .[105263157894736842]         9/31  = .[290322580645161]
                                      28/31 = .[903225806451612]
1/23  = .[0434782608695652173913]     3/31  = .[096774193548387]
10/23 = .[4347826086956521739130]     30/31 = .[967741935483870]
8/23  = .[3478260869565217391304]     21/31 = .[677419354838709]
11/23 = .[4782608695652173913043]     24/31 = .[774193548387096]
18/23 = .[7826086956521739130434]     23/31 = .[741935483870967]
19/23 = .[8260869565217391304347]     13/31 = .[419354838709677]
6/23  = .[2608695652173913043478]     6/31  = .[193548387096774]
14/23 = .[6086956521739130434782]     29/31 = .[935483870967741]
2/23  = .[0869565217391304347826]     11/31 = .[354838709677419]
20/23 = .[8695652173913043478260]     17/31 = .[548387096774193]
16/23 = .[6956521739130434782608]     15/31 = .[483870967741935]
22/23 = .[9565217391304347826086]     26/31 = .[838709677419354]
13/23 = .[5652173913043478260869]     12/31 = .[387096774193548]
15/23 = .[6521739130434782608695]     27/31 = .[870967741935483]
12/23 = .[5217391304347826086956]     22/31 = .[709677419354838]
5/23  = .[2173913043478260869565]     5/31  = .[161290322580645]
4/23  = .[1739130434782608695652]     19/31 = .[612903225806451]
17/23 = .[7391304347826086956521]     4/31  = .[129032258064516]
9/23  = .[3913043478260869565217]     9/31  = .[290322580645161]
21/23 = .[9130434782608695652173]     28/31 = .[903225806451612]
3/23  = .[1304347826086956521739]     1/31  = .[032258064516129]
7/23  = .[3043478260869565217391]     10/31 = .[322580645161290]
                                      7/31  = .[225806451612903]
                                      8/31  = .[258064516129032]
                                      18/31 = .[580645161290322]
                                      25/31 = .[806451612903225]
                                      2/31  = .[064516129032258]
                                      20/31 = .[645161290322580]
                                      14/31 = .[451612903225806]
                                      16/31 = .[516129032258064]

Two Very Large primes

September 17th, 2008

As promised, I can now reveal the identity of the two newly discovered Mersenne primes. The smaller of the two, discovered on September 6 by Hans-Michael Elvenich in Langenfeld, Germany, is


2^{37,156,667} - 1,

an 11,185,272-digit number which you can download here. The larger one was actually discovered first, on August 23, by Edson Smith, who had installed the prime-checking software on computers at UCLA. It is now the largest known prime, weighing in at a whopping 12,978,189 digits, and is equal to

2^{43,112,609} - 1.

You can download it here. Of course, as I suspected, these are both longer than ten million digits, which means that the first one to be discovered is eligible for a $100,000 prize!

These are ridiculously huge numbers. For a little perspective, the total number of atoms in the universe is estimated at somewhere around 10^{80}, a number with only eighty-one digits. Now go back and read again how many digits these newly discovered prime numbers have.

New Mersenne primes!

September 15th, 2008

The Great Internet Mersenne Prime Search just announced not one, but two new Mersenne primes! You might also recall the last time they announced a new prime, in September 2006, so these new primes were found almost exactly two years after the previous one. They haven’t actually announced what the primes are yet, but both of them are almost sure to be longer than ten million digits, long enough to claim the $100,000 prize offered by the Electronic Frontier Foundation! If they both end up being longer than ten million digits, I guess it sucks to be the guy whose computer discovered the second one (just two weeks after the first). You don’t get any money for discovering the second of anything.

Anyway, as soon as they announce the actual numbers, I’ll be sure to let you know!

Teaching precalculus in 2008-2009

September 14th, 2008

This year I will be teaching precalculus via correspondence to two homeschool students. Don’t ask how this happened, it’s a long story, but I’m excited! It will be fun for me to gain more experience teaching and writing, and to experiment a bit with the curriculum in ways that I think will make it more current. I’ve taught precalculus once before, at a public high school in Washington, DC, and ever since that experience I’ve had some strong opinions about ways that the curriculum should be different. Perhaps I’ll write more on that rant later.

At any rate, the point is that I’ll be making a number of my materials available online under a Creative Commons Attribution-Noncommercial license (the same license that applies to all the content on this blog). There are already a couple assignments posted, along with a basic LaTeX tutorial and a syllabus. Feel free to use it for learning, teaching, or whatever. I imagine that the weekly assignments could be profitably used for enrichment, extra credit, or even straight-up assignments as part of other classes at various levels. I’m also making the LaTeX source available so you can even make your own modifications, or just use individual exercises, paragraphs, or whatever, as long as you cite me as the source. I won’t be making solutions available, for hopefully obvious reasons, but if there is enough demand and I have time I might be able to write up some solutions and have them available for distribution to teachers by request, so let me know if you’d be interested.

I’ll probably occasionally write something here when I’ve posted some new materials, but if you’re particularly interested to know each time I’ve posted something new, let me know and I could perhaps set up some sort of automated notification system.

Rational numbers and decimal expansions

September 7th, 2008

As you may remember from school, rational numbers have a terminating or eventually repeating (periodic) decimal expansion, whereas irrational numbers don’t. So, for example, 0.123123123123…, with 123 repeating forever, is rational (in fact, it is equal to 41/333), whereas something like 0.123456789101112131415…, which will never repeat, is irrational.

But do you know why this is true? (Despite what your teachers may have told you, the most important question in mathematics is not how, it is why!) Today I will show why every rational number has a terminating or eventually repeating decimal expansion, and in a future post I will show why every repeating or terminating decimal expansion represents a rational number. From these two pieces of information, of course, we can also deduce that every decimal expansion which doesn’t terminate or repeat must represent an irrational number, and vice versa.

Read the rest of this entry »

Weird black bars in LaTeX images

September 2nd, 2008

Recently I’ve been seeing strange black bars to the right of all the images generated from LaTeX expressions on this blog. But I’m starting to suspect that it’s some sort of bug in Firefox, because when I download the images and view them with some other program, they look fine.


\displaystyle \sum_{k=1}^\infty \frac{1}{k^2} = \frac{\pi^2}{6}

Do you see a black bar to the right of the above formula? Please leave a comment if you do, ideally stating what operating system and browser you use, along with their version numbers. (If you don’t, I guess that would be useful to know too.) Thanks much! I hope to be able to track down the problem with your help.