# Random Walks Mural

I’ve been meaning to give the back wall of my classroom a makeover for a while. This summer I finally found some time to tackle the big project. I took down all the decorations and posters. I fixed up the wall and painted it a nice tan color. Then, I let loose the randomness!

I struggled with what the new mural would be–I’ve thought about it over the last few years. I considered doing some kind of fractal like the Mandelbrot Set. But it should have been obvious, given the name of my blog!! What you see in the picture above is three two-dimensional random walks in green, blue, and red. In the limiting case, one gets Brownian motion:

Brownian motion of a yellow particle in a gas. (CCL)

I honestly didn’t know what it was going to look like until I did it. I generated it as I went, rolling a die to determine the direction I would go each time. I weighted the left and right directions because of the shape of the wall (1,2=right; 3,4=left; 5=up; 6=down). For more details about the process of making it, here’s a documentary-style youtube video that explains all:

Actually, I lied–it doesn’t tell “all.” If you really want to know more of my thought process and some of the math behind what I did, watch the Extended Edition video which has way more mathematical commentary from me. I’ve also posted the time lapse footage of the individual green, blue, and red. Just for fun, here’s an animated random walk with 25,000 iterations:

A two-dimensional random walk with 25,000 iterations. Click the image for an animated version! (CCL)

I think the mural turned out pretty well! It was scary to be permanently marking my walls, not knowing where each path would take me, or how it would end up looking. At first I thought I would only do ONE random walk. However, the first random walk (in blue) went off the ceiling so I stopped. And then I decided to add two more random walks.

In retrospect, it actually makes complete sense. I teach three different courses (Algebra 2, Precalculus, and Calculus) and I’ve always associated with each of theses courses a “class color”–green, blue, and red, respectively. I use the class color to label their bins, to write their objective and homework on the board, and many other things.

The phrase “Where will mathematics take you?” was also a last-minute addition, if you can believe it. There just happened to be a big space between the blue and red random walks and it was begging for attention.

What a good question for our students. The random walks provide an interesting analogy for the classroom. I’d like to say I’m always organized in my teaching. But some of the richest conversations come from a “random walk” into unexpected territory when interesting questions are raised.

Speaking of interesting questions that are raised, here are a few:

• Can you figure out how many iterations occurred after looking at a “finished” random walk? Or perhaps a better question: What’s the probability that there were more than n iterations if we see m line segments in the random walk?
• Given probabilities $p_1, p_2, p_3, p_4$ of going in the four cardinal directions, can we predict how wide and how high the random walk will grow after n iterations? Can we provide confidence intervals? (might be nice to share this info with the mural creator!)
• After looking at a few random walks, can we detect any bias in a die? How many random walks would want to see in order to confidently claim that a die is biased in favor of “up” or “left”…etc?

Some of the questions are easy, some are hard. If you love this stuff, you might be interested in taking a few courses in Stochastic Processes. Any other questions you can think of?

Where will math take you this coming academic year? Welcome back everyone!

# Probability questions from Tanton

Confession: I still haven’t figured out how to use twitter. (Feel free to follow me @mrchasemath, though!) I always feel like I’m drinking from a fire hose when I get on the site–I can’t keep up with the twitter feed, so I don’t even try.

But when I do, I love seeing what people are posting. Here’s a great math problem from James Tanton. He always has such interesting problems!

Feel free to work it out yourself. It’s a fun problem! Here are my tweets that answer the question (can you follow my work?):

It’s hard to do math with 140 characters! 🙂

Here’s his follow-up question which has still gone unanswered. My approach to the first problem won’t work here, and I want to avoid brute-forcing it. (Reminds me of my last post!) Any ideas?

Let us know in the comments…or tweet @jamestanton!

# Four ways to compute a probability

I have a guest blog post that appears on the White Group Mathematics blog here. (My first guest post!) Here’s a taste:

One thing I love about math, and particularly combinatorics and probability, is the fact that many methods exist for solving the same problem.

Each method may have its advantages. The advantage might be conceptual (as in “this makes most sense to me”) or the advantage might be computational (as in “this is the fastest way to do it”).

Discussing the merits of different methods is exactly what math class is for!

For example, check out this typical probability question that could appear in a Precalculus course:

The Texas Ranger pitching staff has 5 right-handers and 8 left-handers. If 2 pitchers are selected at random to warm up, what is the probability that at least one of them is a right-hander?

In fact, it’s one I use in my own Precalculus course and it generated a great class discussion. In teaching it this past year, I ended up showing students four ways to do the problem this year! Here they are…

For the epic conclusion of this post, visit White Group Mathematics. 🙂

# Paradoxes, Infinity, and Probability

I’ve been loving the videos that SpikedMathGames has been posting on youtube. Check out their channel here. In particular, I’ve enjoyed Paradox Tuesday. Here’s one from a few weeks ago which really interested me (if you go to the youtube page, you’ll see I’ve been active in the comments!):

They also cover some famous paradoxes like the Unexpected Hanging Paradox or the  Barber Paradox. If you’ve never heard of these, go watch these now.

I’m especially interested in paradoxes that deal with infinity, countability, and probability. Here’s another great paradox that deals with just those issues that my friend Matthew Wright shared with me a few months ago (thanks Matthew!). It’s called the Grim Reaper paradox (can’t link to the Wikipedia article–it doesn’t yet exist), proposed in 1964 by José Amado Benardete in his book Infinity: an essay in metaphysics, and I first read about it on Alexander Pruss’s blog here, and I quote:

Say that a Grim Reaper is a being that has the following properties: It wakes up at a time between 8 and 9 am, both exclusive, and if you’re alive, it instantaneously kills you, and if you’re not alive, it doesn’t do anything. Suppose there are countably infinitely many Grim Reapers, and before they go to bed for the night, each sets his alarm for a time (not necessarily the same time as the other Reapers) strictly between 8 and 9 am. Suppose, also, that no other kind of death is available for you, and that you’re not going to be resurrected that day.

Then, you’re going to be dead at 9 am, since as long as at least one Grim Reaper wakes up during that time period, you’re guaranteed to be dead. Now whether there is a paradox here depends on how the Grim Reapers individually set their alarm clocks. Suppose now that they set them in such a way that the following proposition p is true:

(p) for every time t later than 8 am, at least one of the Grim Reapers woke up strictly between 8 am and t.

Here’s a useful Theorem: If the Grim Reapers choose their alarm clock times independently and uniformly over the 8-9 am interval, then P(p)=1.

Now, if p is true, then no Grim Reaper kills you. For suppose that a Grim Reaper who wakes up at some time t1, later than 8 am, kills you. If p is true, there is a Grim Reaper who woke up strictly between 8 am and t1, say at t0. But if so, then you’re going to be dead right after t0, and hence the Grim Reaper who woke up at t1 is not going to do anything, since you’re dead then. Hence, if p is true, no Grim Reaper kills you. On the other hand, I’ve shown that it is certain that a Grim Reaper kills you. Hence, if p is true, then no Grim Reaper kills you and a Grim Reaper kills you, which is absurd.

Go visit his blog post for a discussion of why this seems unresolvable, and how it may actually put forward a case for time being discrete rather than continuous. Crazy thought.

There’s something deeply unsettling about this paradox and also the Unexpected Hanging paradox. Anytime we deal with probabilities and certainty, paradox seems to be lurking nearby.

I sometimes ask my students this somewhat related question–perhaps you’ve heard it too:

How many positive integers have a 3 in them? (That is, in their decimal representation. 6850104302 has a 3 but 942009947 does not.)

If you haven’t ever considered this question, take the time to do it now.

Though I actually once worked out the result using limits (like Alexander Bogomolny does marvelously here), it’s easy enough to work out the result in our heads:

First ask yourself how many digits a randomly selected integer has. The number of digits is almost certainly greater than 2, right? There are only 90 two-digit positive integers, a finite number, and there are an infinite number of integers with more than two digits. It follows that if you were to pick one at random from among all positive integers*, it would be almost certain to contain more than two digits.

The same argument could be applied to a larger number of digits. By the same logic as above, we can convince ourselves that ‘most randomly selected integers have more than a trillion digits’. It’s a bit of an incredible statement, really. We rarely ever work with the ‘most-common’ kind of numbers (the big ones!).**

What is the probability that a number with a trillion digits has a 3 in it? Well, it’s almost certain. The probability approaches 100%. If we consider ALL numbers, the probability IS 100% (or is it?). This is a real dilemma. How can we say that 100% of numbers have a 3 in them when this is clearly not true?

We’ve been pretty sloppy here, but regardless, this kind of fast-and-loose infinite probability question is unsettling.

Do you want to try taking a crack at these? Feel free to comment below.

Oh, and Happy Birthday Euler!

_________________________________

# Improper integrals debate

Here’s a simple Calc 1 problem:

Evaluate  $\int_{-1}^1 \frac{1}{x}dx$

Before you read any of my own commentary, what do you think? Does this integral converge or diverge?

image from illuminations.nctm.org

Many textbooks would say that it diverges, and I claim this is true as well. But where’s the error in this work?

$\int_{-1}^1 \frac{1}{x}dx = \lim_{a\to 0^+}\left[\int_{-1}^{-a}\frac{1}{x}dx+\int_a^{1}\frac{1}{x}dx\right]$

$= \lim_{a\to 0^+}\left[\ln(a)-\ln(a)\right]=\boxed{0}$

Did you catch any shady math? Here’s another equally wrong way of doing it:

$\int_{-1}^1 \frac{1}{x}dx = \lim_{a\to 0^+}\left[\int_{-1}^{-a}\frac{1}{x}dx+\int_{2a}^{1}\frac{1}{x}dx\right]$

$= \lim_{a\to 0^+}\left[\ln(a)-\ln(2a)\right]=\boxed{\ln{\frac{1}{2}}}$

This isn’t any more shady than the last example. The change in the bottom limit of integration in the second piece of the integral from a to 2a is not a problem, since 2a approaches zero if does. So why do we get two values that disagree? (In fact, we could concoct an example that evaluates to ANY number you like.)

Okay, finally, here’s the “correct” work:

$\int_{-1}^1 \frac{1}{x}dx = \lim_{a\to 0^-}\left[\int_{-1}^{a}\frac{1}{x}dx\right]+\lim_{b\to 0^+}\left[\int_b^{1}\frac{1}{x}dx\right]$

$= \lim_{a\to 0^-}\left[\ln|a|\right]+\lim_{b\to 0^+}\left[-\ln|b|\right]$

But notice that we can’t actually resolve this last expression, since the first limit is $\infty$ and the second is $-\infty$ and the overall expression has the indeterminate form $\infty - \infty$. In our very first approach, we assumed the limit variables $a$ and $b$ were the same. In the second approach, we let $b=2a$. But one assumption isn’t necessarily better than another. So we claim the integral diverges.

All that being said, we still intuitively feel like this integral should have the value 0 rather than something else like $\ln\frac{1}{2}$. For goodness sake, it’s symmetric about the origin!

In fact, that intuition is formalized by Cauchy in what is called the “Cauchy Principal Value,” which for this integral, is 0. [my above example is stolen from this wikipedia article as well]

I’ve been debating about this with my math teacher colleague, Matt Davis, and I’m not sure we’ve come to a satisfying conclusion. Here’s an example we were considering:

If you were to color in under the infinite graph of $y=\frac{1}{x}$ between -1 and 1, and then throw darts at  the graph uniformly, wouldn’t you bet on there being an equal number of darts to the left and right of the y-axis?

Don’t you feel that way too?

(Now there might be another post entirely about measure-theoretic probability!)

What do you think? Anyone want to weigh in? And what should we tell high school students?

.

**For a more in depth treatment of the problem, including a discussion of the construction of Reimann sums, visit this nice thread on physicsforums.com.

# 87th Carnival of Mathematics

The 87th Carnival of Mathematics has arrived!! Here’s a simple computation for you:

What is the sum of the squares of the first four prime numbers?

That’s right, it’s

Good job. Now, onto the carnival. This is my first carnival, so hopefully I’ll do all these posts justice. We had lots of great submissions, so I encourage you to read through this with a fine-toothed comb. Enjoy!

# Rants

Here’s a post (rant) from Andrew Taylor regarding the coverage from the BBC and the Guardian on the Supermoon that occurred in March 2011. NASA reports the moon as being 14% larger and 30% brighter, but Andrew disagrees. Go check out the post, and join the conversation.

Have you ever heard someone abuse the phrase “exponentially better”? I know I have. One incorrect usage occurs when someone makes the claim that something is “exponentially better” based on only two data points. Rebecka Peterson has some words for you here, if you’re the kind of person who says this!

# Physics and Science-flavored

Frederick Koh submitted Problem 19: Mechanics of Two Separate Particles Projected Vertically From Different Heights to the carnival. It’s a fun projectile motion question which would be appropriate for a Precalculus classroom (or Calculus). I like the problem, and I think my students would like it too.

John D. Cook highlights a question you’ve probably heard before: Should you walk or run in the rain? An active discussion is going on in the comments section. It’s been discussed in many other places too, including twice on Mythbusters. (I feel like I read an article in an MAA or NCTM magazine on this topic once, as well. Anyone remember that?)

Murray Bourne submitted this awesome post about modeling fish stocks. Murray says his post is an “attempt to make mathematical modeling a bit less scary than in most textbooks.” I think he achieves his goal in this thorough development of a mathematical model for sustainable fisheries (see the graph above for one of his later examples of a stable solution under lots of interesting constraints). If I taught differential equations, I would  absolutely use his examples.

Last week I highlighted this new physics blog, but I wanted to point you there again: Go check out Five Minute Physics! A few more videos have been posted, and also a link to this great video about the physics of a dropping Slinky (see above).

# Statistics, Probability, & Combinatorics

Mr. Gregg analyzes European football using the Poisson distribution in his post, The Table Never Lies. I liked how much real world data he brought to the discussion. And I also liked that he admitted when his model worked and when it didn’t–he lets you in on his own mathematical thought process. As you read this post, you too will find yourself thinking out loud with Mr. Gregg.

Card Colm has written this excellent post that will help you wrap your mind around the number of arrangements of cards in a deck. It’s a simple high school-level topic, but he really puts it into perspective:

the number of possible ways to order or permute just the hearts is 13!=6,227,020,800. That’s about what the world population was in 2002. So back then if somebody could have made a list of all possible ways to arrange those 13 cards in a row, there would have been enough people on the planet for everyone to get one such permutation.

I think it’s good to remind ourselves that whenever we shuffle the deck, we can be almost certain that our arrangement has never been created before (since  $52!\approx 8\times 10^{67}$  arrangements are possible). Wow!

Alex is looking for “random” numbers by simply asking people. Go contribute your own “random” number here. Can’t wait to see the results!

Quick! Think of an example of a real-world bimodal distribution! Maybe you have a ready example if you teach stat, but here’s a really nice example from Michael Lugo: Book prices. Before you read his post, you should make a guess as to why the book prices he looked at are bimodal (see histogram above).

# Philosophy and History of Math

Mike Thayer just attended the NCTM conference in Philadelphia and brings us a thoughtful reaction in his post, The Learning of Mathematics in the 21st Century. Mike wrote this post because he had been left with “an ambivalent feeling” after the conference. He wants to “engage others in mathematics education in discussions about ways to improve what we do outside of the frameworks that are being imposed on us by those outside of our field.” As a secondary educator, I agree with Mike completely and really enjoyed his post. Mike isn’t satisfied with where education is going. In his post, he writes, “We are leaping ahead into the unknown with new educational models, and we never took the time to get the old ones right.”

Edmund Harriss asks Have we ever lost mathematics? He gives a nice recap of foundational crises throughout the history of mathematics, and wonders, ultimately, if we’ve actually lost any mathematics. There’s also a short discussion in the comments section which I recommend to you.

Peter Woit reflects on 25 Years of Topological Quantum Field Theory. Maybe if you have degree in math and physics you might appreciate this post. It went over my head a bit, I’m afraid!

# Book Reviews

In this post, Matt reviews a 2012 book release, Who’s #1, by Amy N. Langville and Carl D. Meyer. The book discusses the ranking systems used by popular websites like Amazon or Netflix. His review is thorough and balanced–Matt has good things to say about the book, but also delivers a bit of criticism for their treatment of Arrow’s Impossibility Theorem. Thanks for this contribution, Matt! [edit: Thanks MATT!]

Shecky R reviews of David Berlinski’s 2011 book, One, Two Three…Absolutely Elementary mathematics in his Brief Berlinski Book Blurb. I’m not sure his review is an *endorsement*. It sounds like a book that only a small eclectic crowd will enjoy.

# Uncategorized…

Peter Rowlett submitted this post about linear programming and provides a link to an interactive problems solving environment.

Peter Rowlett also weighs in on the recent news about a German high school boy who has (reportedly) solved an open problem. Many news sources have picked up on this, and I’ve only followed the news from a distance. So I was grateful for Peter’s comments–he questions the validity of the news in his recent post “Has schoolboy genius solved problems that baffled mathematicians for centuries?” His comments in another recent post are perhaps even more important though–Peter encourages us to think of ways we can remind our students that lots of open problems still exist, and “Mathematics is an evolving, alive subject to which you could contribute.”

Jess Hawke IS *Heptagrin Girl*

Here’s a fun-loving post about Heptagrins, and all the crazy craft projects you can do with them. Don’t know what a Heptagrin is? Neither did I. But go check out Jess Hawke’s post and she’ll tell you all about them!

Any Lewis Carroll lovers out there? Julia Collins submitted a post entitled “A Night in Wonderland” about a Lewis Carroll-themed night at the National Museum of Scotland. She writes, “Other people might be interested in the ideas we had and also hearing about what a snark is and why it’s still important.” When you check out this post, you’ll not only learn about snarks but also about creating projective planes with your sewing machine. Cool!

Mike Croucher over at Walking Randomly gives a shout out to the free software Octave, which is a MATLAB replacement. Check out his post, here. MATLAB is ridiculously expensive, and so the world needs an alternative like Octave. He provides links to the Kickstarter campaign–and Mike has backed the project himself. I too believe in Octave. I’ve used it a few times for my grad work and I’ve been very grateful for a free alternative to MATLAB.

# The End

Okay, that’s it for the 87th Carnival of Mathematics. Hope you enjoyed all the posts! Sorry it took me a couple days to post it–there was a lot to digest :-).

If you missed the previous carnival (#86), you can find it here. The next carnival (#88) will be hosted by Christian at checkmyworking.com. For a complete listing of all the carnivals, and more information & FAQ about the carnivals, follow this link.

Cheers!

# Leap Day Birthday Math

## Happy leap day!!!

Here are some leap-day birthday thoughts I discussed with my colleagues and students today:

### What’s the probability of a leap year birthday?

The probability that someone is born on a leap day is $\frac{1}{365\cdot 4+1}=\frac{1}{1461}\approx 0.000684$. Oh wait, that’s not completely true. Leap years don’t really occur every four years. Years divisible by 100 are not leap years, unless also divisible by 400. So, the actual probability is

$\frac{100-4+1}{365\cdot 400+100-4+1}= \frac{97}{146097}\approx 0.000639$.

### What’s the probability of having triplets on a leap day?

One of our RM students is a triplet, born today. What are the chances of that occurring? Well, the statistics on triplets are pretty hard to get right. But let’s say the occurrence of a triplet birth is 1 in 8000. (That’s my informal estimate based on this site and this site.) I think we can say that the probability of being a triplet is 3 times that (right?). Then, the probability of being a triplet born on a leap day is

$\left(\frac{100-4+1}{365\cdot 400+100-4+1}\right)\left(\frac{3}{8000}\right)= \frac{291}{1168776000}\approx\frac{1}{4016412} \approx 0.249 \times 10^{-7}$.

The current US population is 311,591,917, so that means there are roughly 77 triplets in the US with leap day birthdays. Happy birthday to all of you!

Bonus thought question: Iif you have quadruplets born on a leap day, you get to celebrate 4 birthdays every four years, so doesn’t that average out to one birthday a year?

### Half-birthday for those born on August 29

One of my other colleagues has a birthday on August 29th. So today is her half birthday! But it only comes around every four years (roughly). Hooray!

But then that got us thinking about half birthdays: Some people, like those born on August 30th or 31st NEVER have a half birthday. How sad!! This happens to anyone born on August 30th, August 31st, March 31st, October 31st, May 31st, or December 31st. That’s a lot of people without half birthdays.

But wait. When is your actual half birthday? Shouldn’t it be 182.5 days before/after your birthday? That’s not necessarily the same date in the month. For instance, my birthday is May 15. So my half birthday should be November 15, right? Wrong. My half birthday is (May 15 + 182.5 days), which is November 13th or November 14th, depending on if you round up or down. Even accounting for a leap year, it’s still not quite right.

Who else is miscalculating their half birthday? Unless your birthday is in June, April, October, or December, you’re half-birthday isn’t what you think it is. To calculate your half birthday, use this amazing half birthday calculator I just discovered!