This week’s post is a follow-up to a post objecting to the way fractions are taught post from a while back. This is also Occupy Math’s third post about prime numbers. It should be much more down to earth than the first and, unlike the second, there are no insects or implications for ecology. This post explains why students who know about prime numbers will find it easier to do arithmetic with fractions. Being able to find the prime factors of numbers gives those numbers character: prime factors are like personality traits. Another way to say it is that numbers with a prime factor in common form a sort of a tribe with common characteristics. Also, there are some games you can play with prime numbers near the end of the post.

First of all, a *prime number* is a **whole number bigger than one that can be evenly divided only by itself and one**. To make this work the way we want, we also ignore negative numbers as divisors. So, for example, five is prime, it is not divisible by anything but five and one, but four is not prime because it’s divisible by two (in addition to itself and one).

The key tool for this post is the ability to factor a whole number into the prime numbers that make it up. This concerns one of the great wisdoms of our species: the Fundamental Theorem of Arithmetic. This theorem says that every whole number bigger than one is either prime or it can be factored into prime numbers in one and only one way (not counting changing the order of those factors). Here are several examples designed to give you a sense of how this can play out.

- 6=2×3
- 8=2×2×2
- 15=3×5
- 81=3×3×3×3
- 91=7×13
- 105=3×5×7
- 120=2×2×2×3×5
- 255=3×5×17
- 256=2×2×2×2×2×2×2×2

The fundamental theorem says that, once you have the list of prime factors, that is it, game over, no other set of factors will do! The factorizations given as example places the factors in increasing order, just to have a standard way to write them.

**Why are prime numbers important for doing arithmetic with fractions?**

There are two places where prime numbers are very important in fraction arithmetic:

- Putting a fraction in simplest form.
- Finding a common denominator.

Putting a fraction in simplest form is the easier task. Notice that the fractions 2/3, 6/9, and 160/240 are all actually equal to two-thirds. A fraction is *in simplest form* when its top and bottom (or *numerator* and *denominator*) don’t have any factors in common. If we factor 160 and 240 into prime numbers, we get

160=2×2×2×2×2×5.

240=2×2×2×2×3×5.

Cross out any prime numbers that appear in both factorizations and what is left? A two and a three or 2/3. Easy-peasy, at least if you can factor the numerator and denominator into their prime parts.

**Now: common denominators.**

Adding two fractions is easy if they have the same denominator; you just have to add the numerators:

2/7+3/7=5/7

but fractions in simplest form often do not have the same denominator. To add them we have to take them *out* of simplest form. The key step is multiplying the top and bottom of the fraction by the same number (which takes it out of simplest form but does not change its numerical value).

So, for example:

1/3+2/5=(5×1)/(5×3)+(3×2)/(3×5)=5/15+6/15=11/15

… but we need to know that fifteen is the right number to be on the bottom. In this case it’s not too hard to see because, if the bottoms are to be the same, we need a three and a five — that simply yells “fifteen!”.

If the bottoms are more complicated, looking at the prime factors of the bottoms helps us find the smallest number that can be a common divisor. Let’s do the problem:

5/12+7/20

If we factor the denominators we get:

12=2×2×3, and

20=2×2×5.

So both numbers already have 2×2 in common. The fraction with denominator 12 needs a 5 and the fraction with denominator 20 needs a 3. Since 60=12×5=20×3 the common denominator is **60**. We finish the problem like this:

5/12+7/20=(5×5)/60+(7×3)/60=25/60+21/60=46/60

That fraction is a *form* of the correct answer, but it is not in simplest form yet — 46 and 60 have a factor of two in common — so the final answer is

46/60=(2×23)/(2×30)=23/30

and the answer, in simplest form, is twenty-three thirtieths.

**But how do we factor numbers into primes?!?**

So far in this Occupy Math we have seen that being able to break a number into its prime factors let you do some of the trickier parts of fraction arithmetic, but we have not gotten tools for doing that factorization. One thing that saves us is that most whole numbers you encounter in practice are not that big, so the prime numbers below 100 (which are listed in the picture at the top of the post) are a fairly complete list of factors. It also turns out that there are tricks!

- Even numbers — with a last digit of 0, 2, 4, 6, or 8 — are divisible by two.
- Numbers with a last digit of 0 or 5 are divisible by five.
- Here’s a weird one: if the digits of a number add up to a multiple of three, then the number itself is a multiple of three. Consider the number 117. Add the digits 1+1+7=9; nine is a multiple of three so 117 is a multiple of 3. In fact 117=3×39. Since 3+9=12 (another multiple of three) we can factor again and get 117=3×3×13.
- You can always brute-force the factorization by just dividing a number by the prime numbers listed at the top of the post. That sounds like it might take a long time, but it won’t because of the last trick! This trick limits the number of trial divisions needed. It also requires a bit of math thinking. If you divide a number by a number bigger than its square root, you get a number smaller than its square root. The square root of 100 is 10 because 10×10=100 and 100/20=5. Twenty is bigger than ten, five is smaller than ten. Got it? That means that
*if a number is not prime, it has a prime factor no larger than its square root!*.

This last rule limits the number of prime numbers you need to try dividing by. Take the number 113. Since 11×11=121 (which is bigger than 113) any prime factors of 113 must be less than 11. From the list at the top of the page the candidates are just 2, 3, 5, and 7. Using the first three tricks we see 113 does not have 2, 5, or 3 as a factor. Divide 113 by 7 and you get 16.142857 or 16 remainder 1. Anyhow, 7 does not divide 113 evenly, and so we conclude 113 is a prime number.

The first three rules cover a lot of territory: eleven out of every fifteen numbers are evenly divisible by two, three, or five. That means that more than two-thirds of all numbers cough up at least one prime factor to those first three tricks!

**Games to practice your factoring.**

- Figure out if your current age is a prime number or, if it is not, what is your next prime birthday? These are the years that you are “in your prime”.
- Like the XKCD comic above, turn the time into a number and try to figure out if the current time is prime —
*before*it changes! - If you get a number for your order in a coffee-shop, figure out if your number is prime.

These games are all pastimes (Occupy Math factors his order number at the coffee shop most work mornings), but these games build your math muscles and will improve your ability to work with fractions. The basic version of these games is answering the question “is the number prime”. The advanced version is “factor the number into primes”.

In the earlier post on how not to teach fractions, the government handout talks a lot about students “developing a number sense” without really saying what that sense is. Noticing how numbers factor is a big part of developing a number sense — and prime numbers are key to that skill.

This has been a pretty arithmetic-heavy post, but Occupy Math promises that the skills and techniques outlined in the post are helpful for learning basic math. It’s also worth noting that prime numbers have importance far beyond building up your basic math skills. The codes that keep financial transactions secure are built on really big prime numbers and we search for big primes. The most recent news is that we have found a prime number more than 23 million digits long!

Prime numbers are all over math. If you would like to see more about them — or other posts on tools for surviving and thriving in math, let Occupy Math know. Please comment or tweet!

I hope to see you here again,

Daniel Ashlock,

University of Guelph,

Department of Mathematics and Statistics