Thursday, January 29, 2015

Advancing the calendar trick

I've written twice (first and second) about classroom experiences with a simple calendar trick that I originally got from Calendar Puzzles via Denise Gaskin's monthly newsletter. As happens so many times with these things, ideas from the kids make these activities into deeper and more interesting than I could have imagined on my own.

On Tuesday, some of the first graders gave me their sums: 168 and 198. I immediately knew something was up. In the original calendar game, the square with the largest possible sum is the 23-24-30-31 square:


This has a sum of 108. I asked the students if they were sure of 168 and 198. They giggled, then the teacher smiled and told me she had checked it. What was going on?

My homework
I didn't have any immediate ideas, so I promised the kids that I would work on their puzzles. I told the kids that it was great to get my homework from them this time!

See through paper
One clue was that we were using a special calendar today and the paper was slightly see-through. This gave me an idea that the kids had turned the paper over and were seeing the numbers through the page with digits reversed. At first, I thought they were transforming 2s to 5s and vice versa, but was able to find 168 just by reversing digits.

How many carries?
For the original game, the crucial insight is simply that there are 7 days in a week and the calendar is organized into weeks. That means there is a simple relationship between each of the numbers in our 2x2 squares. Add a bit of simple algebra and you have an easy formula relating the upper left square of your 2x2 matrix to the sum (or, if you want to be fancy, a different formula relating whichever square you want to the sum).

For the reversed game, though, it isn't quite so easy. The relationship between the numbers can take one of several forms and is rather messy. I did manage to get 168. Can you?

But, I still couldn't get 198.

Two little helpers to the rescue
Last night, I "cheated" and asked for help. As J1 and J2 got ready to sleep, I asked what they thought their friend might have done to get 198. Their ideas from brainstorming:

  • maybe the friend made an addition error
  • maybe the friend also transformed 2s to 5s when reversing the paper
  • maybe he summed a 3x3 square instead (which quickly gave rise to 4x4 and 5x5)
3x3 square? Interesting! Work through the algebra again and you can quickly see that there is (always!) a 3x3 square whose contents sum to 198.

Some further exploration, for you
More fun follow-on questions:

  1. If the kids are allowed a choice of 2x2 or 3x3 section, but they still only tell you the sum and not the size of their square, can you still figure out which days they chose? Are there any conditions you might put on which month is chosen that allow you certainty in finding the square?
  2. What if you allow 4x4, too?
  3. Why stop at 4x4? What size squares are possible on a 1 month calendar?
  4. If you make a year calendar instead, what sums are possible? If you are given the size and sum of a square, how close can you get to finding the source? In other words, how many squares have the same sums?

If you have other ideas, please let me know in the comments!

Wednesday, January 28, 2015

23 isn't prime (a short bedtime story)

Who: J2 and J1
Where: bedroom
When: after lights out

Without any particular prompting, this conversation started, probably as an excuse to stay up a couple more minutes.
J2: 23 isn't prime because it is divisible by .1
J0: Interesting. What number multiplied by .1 is 23?
J2: 13
J0: Hmm. 13 x 0.1 is thirteen 0.1s, so I think that would be 1.3
<J1 and J2 proceed to guess what values for 23/0.1>
J2: it has to be a multiple of 10
<a couple more guesses
J1: 230
J0: So, if you let yourself have fractions or decimals, then 23 isn't a prime. Another way to say that is 23 isn't a prime in the rationals.
J2 (initially copying): 23 isn't a prime in the rationals. Hey, nothing is prime in the rationals!
J0: Usually when we say "prime" by itself, we are just talking about the integers, like -2, -1, 0, 1, 2. if we stick to that, what do you think about 23?
J1 and J2 together: its prime!
J1: what about e, is it prime?
<brief continuation where I say that I know some other primes and extensions of the definition of prime, but I don't know one in which e is prime>

Math lies

This reminded me of a math blogosphere exchange recently where teachers were talking about the "little white lies in math." What do I mean:
  • You can't subtract 7 from 3 (said when introducing subtraction and using a model of taking away physical objects.  
  • You can't divide 5 by 2 (distinguishing evens and odds, sharing whole objects, division within integers)
  • You can't take a square root of -5
  • You can't divide by 0
  • You can't sum +1 - 1+1 -1 +1 -1 +.... 
  • etc etc
The consensus view agreed was that these types of statements are fine, that students will get over it when they are introduced to more advanced concepts.

I don't like it.

Ideally, we would take time to explore what it would mean if you could do those "forbidden" things. If time's not available now, offer to make time later. Maybe these are luxuries for someone who doesn't have to teach to an upcoming test, so if you can't explore with them, encourage the students to think about it on their own.

At the very least, use the right words to describe what you are (not) doing: "we can't take a square root of -5 in the real numbers." Sure, not all the students will get it, but hearing this caveat will clue them in that (a) this isn't a universal rule, so something special is happening, (b) there is more coming in the future and (c) what to do with their old understanding when they are finally shown the extension/clarification

Oh well, it seems to work for us.

Monday, January 26, 2015

Programming project ideas

1. Make a version of this game:
original source

2. make a program to simulate multi-hinge machines
3. create a blog reader that removes gender and racial identifiers.
4. mathman game
5. fighting monsters
6. animation of a body part/system (J1 suggested heart and blood circulation)
7. game avoiding oncoming bullets/arrows, like this
8. Pico/Fermi/Bagel
9. the finger game
10. draw a picture of something from nature (bird, flower, plant) from Ajarn Wachara

This is hard (collected musing about teaching)

who: J0
when: last several days

Here is an accumulation of teaching puzzles. Experienced educators, please feel free to point me in the right direction!

1. This is Hard

I saw a recent twitter exchange around a frequent student comment:
I realized that I had always instinctively seen this as a budding excuse and brushed it aside. Most of the twitter comments seemed, to me, in a similar spirit. Maybe it isn't an excuse? What are the other possibilities?
  1. I'm not confident, could you reassure me?
  2. I'm not confident, can you give me an excuse not to try?
  3. I don't understand what is being said (the concept we are working on or the problem statement)
  4. I don't know what I'm being asked to do
  5. I don't have ideas on how to attack this problem
  6. I think I know what to do, but I don't know how to do it
  7. I think I know how to do it, but it will take effort to overcome every step
  8. I know how to do it, but the work required is detailed and tedious
  9. Any NP problem can be reduced in polynomial time to this problem (see here). Admittedly, this is only for advanced students.
  10. This is interesting! This is fun!
Are there other possibilities? Don't all of these require a different response from the teacher?

2. Hate to be wrong

One of our children really hates to be told that he has gotten something wrong. I won't describe all the symptoms, but let me say again, he hates it!
How should we deal with this?
  • Avoid telling him that he is wrong: instead, ask for him to explain his thinking ("How did you get that?") or say that we don't understand. In particular, encourage him to use a range of tools to explain and clarify his thinking (manipulatives, pictures, alternative models).
  • Assign machines to be the bad cop: let him work out a similar problem in a computer environment where he is getting feedback from the machine, not a person.
  • Role play instances of being wrong: set up safe opportunities for him to experience being wrong. How can we do this?
  • Talk about why it is ok to be wrong: this shows he didn't understand something and is an opportunity to learn
  • Work on self-regulation strategies to stay/become calm: count to 10, walk away, think about something else
  • How to engage when something is wrong: use different language to explain, ask questions, draw a picture, describe how he was thinking about it
Perhaps related to this, he hates to lose when playing games, though this has been getting slightly better over time as his standard for winning has shifted from (1) being ahead/advancing more quickly at all times to (2) winning every instance of a game to (3) winning the majority of games in a repeated sequence. Since that seems to be developing in the right direction, I'm not looking to push it faster.

3. Games are competitive, no?

In a class today, one student didn't want to play a math game because of the competitive wrapping: "first person to reach 100 wins!"

How can I shift the tone so that the games are about exploring patterns, investigating relationships, asking questions, making observations and testing ideas?

Even for the kids who are excited and stimulated by competition won't get the message if they are focused on "winning" the game.

4. Thinking about learning

When should we explicitly talk about learning and study techniques or should we just model them and train the students to apply them in particular instances?

This checklist seemed related:

More calendar play and Nim variation (math games class 9)

Who: Baan Pathomtham 1st and 2nd grade classes
Where: In school
When: after science and before lunch

I can guess your numbers (again)

Since we had a long break, we decided to remind the kids about this calendar game. This time, we used a pretty calendar that was a gift from a friend recently visiting from Nepal.

We split the kids into 2 or 3 groups (varied by class) and had them choose a block of numbers to challenge me. As each announced their sum, I would write out the 2x2 square and then give them a sum to find. This has two purposes: first as practice repeatedly calculating and second to encourage them to look for patterns.

In the calculation practice, it often occurred that students would announce an impossible result (when all 4 squares are filled with dates, the sum has to be a multiple of 4). I think they were almost as surprised to be told that they had gotten the sum wrong as when I told them their squares!

Looking at patterns, we talked a bit about their searching strategies. If I told them 24, then they knew it they didn't need to examine any square that had a 20 or larger because that would be too big. One student made an observation that the diagonals of the 2x2 square have the same sum, so he started working on the idea that cutting the sum in half would be helpful.

We also explored this question: can 21 ever appear as the sum in one of our squares? Students were quick to see that it could be in a 2x1 square (days 10 and 11), but had to do a lot of searching to see that it wasn't possible on their particular month. For some students, we started looking at what numbers do appear as possible sums. Continuing this way will eventually help them realize how I can "magically" determine their starting grid.

Magic 1089

We showed them another surprising result. Each student writes down a 3 digit number with all distinct digits and digits in decreasing order. If you want to follow along at home, 211 doesn't work because the digits aren't distinct while 354 isn't allowed because the digits aren't in decreasing order, while 921 is ok. I will use that to illustrate the trick
Step 2, reverse the digits and subtract. For our illustration, 921 - 129 = 792
Step 3, reverse the digits of the result and add to the result. 792 + 297 = 1089.
Try it with your own number and . . . get 1089. Can you figure out why it works?
Some observations from the students: the middle digit after step 2 appears to always be a 9. Also, the numbers 792 or 297 seem to appear frequently in step 2.

Nim Variation: add to 100

Our new game this week, for the second graders, was to play a NIM variation on the 100 board. Two players take turns adding an integer from 1-20 to an accumulating sum. The player who gets exactly 100 wins.
For this game, we used 100 boards and buttons to record our sum.
We will play this game next week with the first graders who spent more time on the calendar exploration and didn't have enough time this week.


Try 5 different numbers and check to see if the 1089 trick always produces the same answer. Try with 2 digit numbers as well. What is the result then and is it always the same, no matter which numbers you choose to start? Parents: encourage your kids to also try out 4 digit or longer numbers if they want and to make conjectures about what is happening to make this work.

Creepy Eyes (programming class 14)

Who: Baan Pathomtham Grade 5
Where: at school
when: Monday morning for 2 hours

Note: These activities were based on this program I found in the pencilcode activity directory: Son of Eyes. This was a very productive class because it helped tease out many misconceptions about functions and variables.

Homework Discussion

Reviewing the students' accounts this weekend, I saw some programs written for geometry (great!) but no more progress on the function machines and nothing that indicated they had thought about their projects for this term. As a result, we did not discuss homework today ;-<

Simple Function

The first challenge was to figure out what this program does:
makeeye = (x, y) ->
    b = new Sprite
    drawon b
    dot black, 30
    dot white, 28
    fd 7
    dot limegreen, 14
    drawon window
    b.moveto x, y
    forever ->
        b.turnto lastmouse
makeeye -1, 45
As usual, reproducing the program and watching it perform was an acceptable strategy. Through the course of this warm-up, we had a chance to review a lot of the mechanics of writing programs, particularly the use of spacing Coffeescript/pencilcode.

Creepy functions and power loops

As a next version, I gave them a suggestion to integrate this code snippet into their earlier program:
for [0...10]    x = random [-200..200]
    y = random [-200..200]
For the most part, they understood what the loop was doing and were comfortable with that piece. However, integrating it with the makeeyes function proved to be a significant challenge and was really helpful for showing that none of the students yet understand the structure of a function. Essentially, no one knew how to run the function again or to run it with new input variables. We stopped the experimenting and talked about the key components of a function:
  1. Name and definition
  2. Input variables
  3. Body
  4. function call: function name and inputs
After this discussion, they seemed to be clearer about how functions work, but we will need to review again at least one more time.

A funny surprise

I showed the students one version I made of the creepy eyes program. Gun was the first to test it out. I encourage you to try it out several times with different input variables. See if you can find the little surprise I included for one of our precocious learners.


This term, we want each of the students to work on a project of their own. The homework this week is to write out a detailed description of the project they want to develop. As no one had previously thought about potential projects, we gave them the following categories as suggestions:
  • A game: there are many types, including animated games, text-based games, playing against a computer or against a friend, etc
  • An animation or a movie
  • A drawing (for example, an animal or plant they've learned from Ajarn Wachara)
  • A tool to explain some mathematics to the younger students

Sunday, January 25, 2015

CD's required reading

Christopher Danielson (@Trianglemancsd) started a twitter conversation listing essential reading for people who want to make pronouncements about mathematics education. Of course, this serves a dual use for anyone who wants to improve their own practice, in which spirit I offer this accumulate list and links:

  1. Yes, as notes, Children's Mathematics. And Extending Children's Mathematics.
  2. And Kamii and Wu.
  3. And Fosnot & Dolk's Young Mathematicians at Work.
  4. And the STANDARDS, not one project's representations of those standards.
  5. It should also be mandatory to compare and contrast the Common Core Standards to those (past or present) of a single state.
  6. At least one Essential Understandings book from NCTM.
  7. At least one article from the Rational Number Project.
  8. My blogs.
  9. And blog.
  10. Oops. Almost left out the Ball/Bass/Hill team. At least one article with at least two of those names on it.