Transcript Slide 1

27/03/09
David Goulding
Maths Magic
• These slides were presented to the parents during the final class of
the course
• Main aim is to give an overview of the different topics covered during
the eight weeks
• CTYI is geared towards students demonstrating high academic
achievement over a range of ages
• Maths Magic was run for students ranging in ages between 8 and 12
• While classes were planned in advance, it was sometimes necessary
to change course during the class in order to keep interest levels high
27/03/09
David Goulding
Maths Magic
Natural Numbers
1
1 1
Triangular Numbers
1 2 1
1 3 3 1
1 4 6 41
1 5 10 10 5 1
1 6 15 20 15 6 1
1 7 21 35 35 21 7 1
1 8 28 56 70 56 28 8 1
27/03/09
David Goulding
Maths Magic
Odds of Getting an Exact Number of Heads or Tails
1
H
T
1 1
HT TH
TT
1 2 1 HH
1 3 3 1 HHH HHT HTH THH TTH THT HTT TTT
1 4 6 41
Odds of getting a head or tail is 1/2
1 5 10 10 5 1
1 6 15 20 15 6 1
Rosencrantz - Heads???
1 7 21 35 35 21 7 1
1 8 28 56 70 56 28 8 1
27/03/09
David Goulding
Maths Magic
Rolling dice
Well there are six numbers on a die, 1-6, if the die is fair (that
is not biased towards any one number), then the chances of
getting any one of the numbers is 1/6
What about if I roll a pair of dice
and look at the sum??
36
12
18
36
27/03/09
David Goulding
Maths Magic
Odds of Winning Dave’s Lottery
Dave’s lotto is a simple game, there are six numbers (1-6) you
must choose four of them: what are the chances of winning?
Let’s look at the combinations
(1,2,3,4) (2,3,4,5)
(1,2,3,5) (2,3,4,6)
(1,2,3,6) (2,3,5,6)
(1,2,4,5) (2,4,5,6)
(1,2,4,6) (3,4,5,6)
(1,2,5,6) (1,4,5,6)
(1,3,4,5)
(1,3,4,6)
(1,3,5,6)
27/03/09
Maths Magic
There are 15 ways to choose 4 numbers from 6, we can see
this from Pascal’s triangle
1 6 15 20 15 6 1
The general formula for calculating combinations is in fact
given by
n
n!
Cr 
r!(n  r )!
Where
n!=nx(n-1)x(n-2)x…x3x2x1
Let’s look at example above, want to choose four numbers
from 6, so that’s
6
27/03/09
C4 
6!
6 * 5 * 4 * 3 * 2 *1
720 720



 15
4!*2! (4 * 3 * 2 *1) * (2 *1) 24* 2 48
David Goulding
Maths Magic
Odds of Winning The Irish Lotto
In the Irish Lotto there are 45 numbers and we must choose the correct
six numbers, using the same formula as before we have
45
45!
C6 
6!*39!
This works out to be 8,145,060 different combinations
(again trust me on this one!!)
Conclusion: Don’t play the Lotto
27/03/09
David Goulding
Maths Magic
Let’s suppose we have some sort of magic box, which we’ll call
the squaring box, we put a number into the box and it give back
the square of the number, for example
2
4
We then generalised this to the following function:
f (t )  t
27/03/09
David Goulding
2
Maths Magic
This lead us to be able to draw our first graph with the students,
so we drew a graph of “t-squared” – we looked at this then in
relation to graphs of running times for the students
450
400
350
300
250
Series1
200
150
100
50
0
0
27/03/09
5
10
15
David Goulding
20
25
Maths Magic
A perfect number is a number whose divisors (excluding itself)
add up to the number!
Let’s look at my birthday : June 28th
Divisors of 6 are 1,2,3,6.
So 6 is perfect!!
Now 1+2+3=6
Divisors of 28 are 1,2,4,7,14,28.
So 28 is perfect!!
Now 1+2+4+7+14=28
The next two perfect numbers are 496 and 8128 – you can trust
me on those ones!!
(unsolved) Are there any odd perfect numbers?
27/03/09
David Goulding
Maths Magic
A prime number is a number divisible only by itself and one.
(We do not include one as a prime)
Let’s look at primes, well 2,3,5,7,11,13,17,19 are all
primes…..is there a way of generating the primes, well yes we
can use the famous Sieve of Eratosthenes
27/03/09
Maths Magic
Now the Sieve is all well and good but it is extremely time
consuming to carry out….is there another way
Well there are tests for certain types of primes but there is no
magic way of writing done all the prime numbers!!
How many primes are there?
The answer is that there is an infinite number of primes, this
was proven in the class as follows.
Suppose we had only a finite number of primes, say 2,3,5,7
and 11. Now we know that any number is either prime or
composite (that is it is divisible by some number-in fact divisible
by primes). What about the number
(2x3x5x7x11) + 1 = 2311
well this is not divisible by any of 2,3,5,7,11 therefore it is either
prime or we have not included a prime in our list!! (Turns out
David Goulding
Maths Magic
this is prime as well)
First introduction to Graph Theory!
27/03/09
David Goulding
Maths Magic
One possible solution that
the class came up with:
27/03/09
David Goulding
Maths Magic
4
Why does this work? Well
Euler said that if we have
either 0 or 2 nodes of an odd
degree then the problem will
have a solution – Try find
another possible solution,
simply by adding additional
paths and then counting the
number of lines entering
each node
5
3
So the Bridges of
Konigsberg turned out to be
the forerunner of modern
day graph theory
4
27/03/09
David Goulding
Maths Magic
Monty Hall Problem
The Monty Hall Problem is based on the game show “Let’s
Make a Deal” which was a very popular tv show in the States in
the 1960s and 1970s.
In the problem, there are three doors 1, 2 and 3, behind one of
the doors is a car but behind the other two there are goats!!
Haven chosen a door, Monty Hall
would then open a door for the
contestant to reveal a goat.
Monty Hall would then offer the
chance to swap doors. The problem
was then whether it was more beneficial to stick or swap
My favourite demonstration is by Professor Marcus du Satoy
27/03/09
David Goulding
Maths Magic
Switching Loses
Switching Wins
Switching Wins
So 2 out of 3 times you win by switching, so probability of winning
by switching is 2/3, while it is only 1/3 by staying
27/03/09
David Goulding
Maths Magic
Summing Consecutive Numbers
When Gauss was fourteen, his teacher suffering from a heavy
night at the opera the evening before decided that the best way
to keep the students quiet was to get them to add all the
numbers from 1 to 100. Unfortunately for him, Gauss was a bit
too clever even by our standards this is what he did
1
+ 2 + 3 + … + 98 + 99+100
100+99+98+
…+3
+2
+1
101+101+101+…+101+101+101
27/03/09
David Goulding
Maths Magic
Summing Consecutive Numbers
So we have that the sum is simply (100*101)/2 (since we
counted from 1 to 100 twice!)
We can extend this to the generalised formula
n(n  1)
i 1 i  1  2  3  ... n  1  n  2
n
Which in simply terms, means if we want to sum all the
numbers from 1 up to a certain number, we simply take the
number, add one and multiply by the original number and finally
divide by 2…hey presto we have the sum
Incidentally it’s 5050 in the original problem
27/03/09
David Goulding
Maths Magic
Number of Squares on a chess board?
Well exactly how many squares are there on a chessboard?
No, not 64!! You forgot about the squares of size 2,3,4, etc.
How many of size 1? 64
Size 2? 49
Size 3? 36…etc.
See the pattern?
It’s the sum of the square
numbers from 1 to 8
# of squares = 1+4+9+16+25+36+49+64 = 204
n(n  1)( 2n  1)
i 1 i  1  2  3  ... (n  1)  n 
6 Maths Magic
27/03/09
David Goulding
n
2
2
2
2
2
2
Matrix Multiplication
 2 3

A  
 4 1
 2 3 1

AB  
 4 1  3
 1 0  2

BA  
 3 2  4
1 0

B  
3 2
0  11
  
2  7
3  2
  
1  14
6

2
3

11
Matrix Multiplication was introduced in order to show the
students that sometimes the order of multiplication is important.
Codes and Ciphers
In this class, the students were introduced to some simple
codes and the corresponding ciphers
These included a simple numerical substitution, where A=1,
B=2, C=3, etc.
The Caesar Cipher in which the letters are moved along the
alphabet by a fixed number of positions for example A=H, B=I,
C=J, etc
Sometimes these are easy to break…especially if somebody is
David Goulding
Maths Magic
a VAXTMXK
Another example was the well
known Pigpen cipher, shown to
the left with coded and decoded
message below
This class made use of Simon
Singh’s Code Book
27/03/09
David Goulding
Maths Magic
Final Problems
Parents you are all to enter into a deal with your kids, I am
going to propose a problem to you all and you are going to try
and solve it yourselves. If you fail to do so by tomorrow you
must give 1c to your child, if you can not solve it on Monday
you must give them 2c, 4c on Tuesday if you haven’t solved it
and so on until 30 days have elapsed
Sounds like a pretty fair deal, don’t you agree?
Here’s the puzzle so:
27/03/09
David Goulding
Maths Magic
Being an extremely cruel and vicious maths teacher, I have
decided to take ten of the students and stand them in a line facing
the wall, one behind the other. On each of their heads I will place
a hat, either black or white, I don’t know how many of each colour
that is up to me to choose when I see fit. Now the kids are not
allowed to speak or communicate once they are placed in the line.
When I say so the kids starting from the back must tell me what
colour hat they are wearing, if they pick the wrong colour
unfortunately they will die. However if they pick the right colour I
will let them live (this time!).
Your puzzle is to come up with the best strategy for the kids in
order to save as many as possible…and just so you know you can
definitely save at least nine of the kids!!
And just for completion, if you don’t manage to solve the problem,
in 30 days time you will owe your child
€10,737,418.23
Best get working on that problem I guess!!
27/03/09
David Goulding
Maths Magic