Sage Interact: Superformula

In an earlier post on Spirographs, I mentioned I had found some of the information on the matheminutes website. That site had a nice post on the Superformula which I read as well.  The references on the Wikipedia page mention websites such as this for plotting but as we know by now Sage can do just about anything. I've put together a Sage Interact manipulative that lets you experiment with the Superformula on your own. Here is the manipulative running in the Sage Cell Server.

You can find the code to create the manipulative on the Python/Sage page and the output above is on the Sage Output page

Chess Basics: Double Check

Continuing with covering the basics of chess, I've added another post on double check which (aside from checkmate) is the strongest type of attack. That's because there is only one way to respond to a double check: move the king immediately. You can find the details, as a tex file and a PDF file, on the Chess page.

The Rational Numbers Have Measure 0

What does "measure 0" mean? Think of it this way: take a number line where the integers are, say, 1 centimeter apart. That number line has infinite length. Color the rational numbers blue and the irrational numbers red. The length of the number line can be thought of as having a blue length and a red length which combine to give us the infinite length of the number line. To say that the rational numbers have measure 0 means the length attributed to the rational numbers (blue) is 0 centimeters. Therefore, the red length is infinite in length. This is an amazing result which is more compelling than talking about the rationals as being like stars against the blackness of the irrationals (from the excellent TED-Ed video "How Big is Infinity"). Surprisingly, it's not difficult to demonstrate. What is surprising, though, is that it never seems to be mentioned at the high school level. What a shame!

I feel that every high school student should learn the basic idea because this incredible result contradicts the reasoning in an earlier post that made it seem (with the help of a Sage Interact manipulative) every number is rational. That "demonstration" is simple, logical, and wrong. Combined with the fact that the rational numbers have measure 0 you have to agree with the teaching point: proof is necessary, even when things seem obvious.

Only students who have knowledge of limits and the infinite geometric series can truly taught the lesson. Students without this knowledge will have to fall a little bit short: the rational numbers are a very, very small part of the real number system. It's still a valuable lesson. The details can be found in a PDF along with its tex file on the Handouts page.


Listing the rationals in [0,1]

I already posted here that every student should learn that the rational numbers have measure 0 (though we wouldn't say it that way). It's a long term lesson that beautifully illustrates how things that may seem obviously true are, in fact, false. Therefore, proof is a necessary part of mathematics.

Ordering the rationals in [0,1] using a function as I've done is an unnecessary step in the process. It complicates the proof and could be left out. In fact, I think it should be left out if your students aren't going onto calculus where we expect more rigor. For students who in calculus or precalculus, seeing a function that can order the rationals is a nice step to have: it's easy to understand why the function works and it uses a series they should know. In contrast, the function typically used to show all the rationals can be ordered is not easily understood. Additionally, the function from the rationals to [0,1] is multivariable and discrete, a nice reminder to students that functions don't have to go from the real numbers to the real numbers.

Listing the rationals in [0,1] is a good intermediary step to show precalculus/AP calculus students when they are studying functions (but before they are exposed to ordering all the rational numbers). You can find the details on the Handouts page (tex file and PDF output).

How do I...? (change the default font)

I've added a new page to the How do I...? section of the LaTeX page on changing the default font. Virtually everyone who uses $latex \LaTeX$ eventually gets bored with the default font and wants to change it. The simplest way to do so is by using the correct packages. If your document contains mathematical formula then you'll want to make sure the font you choose has support for mathematics.

The page on changing the default font is also located on the sidebar or you can click here.

The most important lesson of high school math

The most important lesson of high school mathematics is something that I've never heard anyone mention at the high school level: the rational numbers have measure 0. That's  high level "math-speak" that you can't use with high school students---but you don't need to. Some of the work has already been done: students see the reasonable argument that all numbers are rational (the subject of this post) and then they learn that there is a number (the square root of 2) which is irrational. Other steps should have been covered: the rational numbers can ordered but the real numbers cannot (so the real numbers are a bigger order of infinity. But to show that the irrationals (the difference between the reals and rationals) is so much bigger than the rationals seems to never get touched. An excellent video on the topic was posted on TED-Ed recently illustrates what I mean. With the title "How Big is Infinity?" it takes you through most of the steps, minus the math, and even adds on some extra information about undecidable problems, but it never comes to the logical conclusion of the steps. Instead, it mentions that (from about 4:50 to the 5 minute mark) that the rationals are like the stars in the night sky and the irrationals are like the blackness. That's a poetic way to get people to think about the difference but is, in my opinion, a shame because the final steps of actually demonstrating the rationals are an insignificant part (with respect to quantity [not importance]) of the real numbers isn't that difficult. More importantly, it replaces the poetic description with something more quantitative.

Although you need calculus to cover it correctly, you can still get the basic idea across without resorting to calculus. You'd just have to take smaller steps and more time in making the point but that's okay: this is a lesson that gets built over years before finally being completed. In addition to the steps already covered (above), I'd make sure that more math gets used in the explanation:

  1. Show that $latex \sum_{i=1}^{n}i=\frac{n(n+1)}{2}$. I posted on that here.
  2. Use the series to find a function from the positive integers to the rational numbers in (0,1], which you say has length 1 centimeter.
  3. Modify the function to include the point 0 as well (so the function now goes from the positive integers to the rational numbers in [0,1]
  4. Use the fact that the rationals can be ordered to cover them with paper having length at most $latex .111\overline{1}$ centimeters.
  5. Show that every rational number can be ordered (less math here, as shown in the video) and therefore (as in 4) the entire numberline (having infinite length) can be covered with at most $latex .111\overline{1}$ centimeters of paper.
  6. Observe that you could have used even less paper to cover the rationals. At this point the basic idea has been made for non-calculus students. For calculus students continue on:
  7. Students who have worked with limits discover that the length of paper you need to cover the rationals has length 0.
This lesson is the logical culmination of high school mathematics and it highlights the importance of proof in mathematics. After seeing for themselves that all numbers are rational they are led, inexorably, to the conclusion that the picture they saw is misleading and wrong. You've even got a teaching point: Proof is necessary, even when things seem obvious.
I'll explain the other steps in more detail in future posts; the teaching point has been added to the Teaching Points page.


Problems: Distance in 3D

Students need to understand that the Pythagorean Theorem is important because it gives us a way of calculating the distance between 2 points in the plane. For students going on in math (eg multivariable calculus in college), the Pythagorean Theorem allows us to find the distance between points in 3 dimensions as well. So it makes sense to foreshadow this using a 3 dimensional rectangular prism.

Find the distance between point D and point F.

You can change the numbers as you see fit or remove the blue line if you want because the $latex \LaTeX$ file for the diagram (along with cropped PDF) is on the Graphics page. The problem is posted on the Problems page.

Amidakuji are 1-1 functions

In an earlier post on Amidakuji, posted here, I mentioned that students in a class of mine brought these interesting structures to my attention. Since I couldn't find them on the internet by searching words like "Japanese line functions", I didn't know their was a connection between these structures and group theory. Start with the diagram from last time:


Read the "rungs" of the "ladder" from high to low and left to right:


These rungs are the transpositions of the symmetric group on letters a,b,c, and d. To see where the letters map to, put a letter in on left and see where it goes:

a (a,b)(c,d)(b,c)(b,c)(a,b)(c,d)(b,c)(a,b)  becomes b (c,d)(b,c)(b,c)(a,b)(c,d)(b,c)(a,b) becomes c (b,c)(a,b)(c,d)(b,c)(a,b)  becomes b (a,b)(c,d)(b,c)(a,b)  becomes a (c,d)(b,c)(a,b) becomes b. Therefore letter a goes to letter b. Put in letter b on the left and it you'll get: b(a,b)(c,d)(b,c)(b,c)(a,b)(c,d)(b,c)(a,b) becomes a(c,d)(b,c)(b,c)(a,b)(c,d)(b,c)(a,b) becomes b(c,d)(b,c)(a,b) becomes c. Therefore letter b goes to letter c. Likewise, c(a,b)(c,d)(b,c)(b,c)(a,b)(c,d)(b,c)(a,b) becomes d(b,c)(b,c)(a,b)(c,d)(b,c)(a,b) becomes c(b,c)(a,b) becomes b(a,b) becomes a, so letter c goes to a. You can confirm that letter d goes to letter d.

Of course, even if I had known this, it's not an explanation my students would have understood. I ended up going for a proof by contradiction and it took me a day or 2 to work out an explanation that some of the better students could understand. You can find the proof posted on the Handouts page.

This is definitely too complicated for your typical class. I only covered it because many were quite interested and several were capable of understanding my sketch of the proof.

How do I...? (type in color)

I've added a new question to the How Do I....? section of the LaTeX page. Today's addition is on getting color into your document. That means it's time to talk about packages as well. Declaring packages in your LaTeX document will allow you to do just about anything and everything you can imagine: color, advanced math, graphics, setting margins, changing fonts, and so on. Using the xcolor package will let you use color as well as give you an incredible amount of control over the different colors you can use. The new page can be found on the sidebar, or you can click here.