The post Ask Uncle Colin: an unexpected Golden Ratio appeared first on Flying Colours Maths.

]]>Dear Uncle Colin,

Why is $\cos(36º)$ equal to $\frac{\phi}{2}$? I find trigonometry difficult and, uh, let’s say I have some demons to banish.

Puzzled Educator Noticed That A Golden Ratio Appears Magically

Hi, PENTAGRAM, and thanks for your message!

I would imagine there are several ways to demonstrate this, but I’m going with the first one to jump into my mind: trigonometric identities.

**Identity number 1**: $\cos(xº) \equiv -\cos(180º-xº)$ - and in particular, $\cos(36º) = -\cos(144º)$. Because $\frac{144}{36} = 4$, this means 36º is a solution to $\cos(x) + \cos(4x) = 0$ [*].

**Identity number 2**: $\cos(2\theta) = 2\cos^2(\theta) -1$. And, by extension, $\cos(4x) = 2\cos^2(2x) - 1$. By further extension, $\cos(4x) = 2(2\cos^2(x)-1)^2 - 1$.

That means, if I let $c = \cos(x)$, equation [*] becomes $2\left(4c^4 - 4c^2 + 1\right) + c - 1= 0$, or $8c^4 - 8c^2 + c + 1 = 0$.

A “fairly obvious” solution to this is $c = -1$ - the first pair of terms factorise as a difference of two squares, so $(c+1)$ is a factor of both ‘halves’.

Factoring that out gives $(c+1)\left(8c^3 - 8c^2 + 1\right) = 0$.

That’s *less* obvious, but $c=\frac{1}{2}$ is also a solution to this, so $(2c-1)$ is a factor. Dividing it out gives $(c+1)(2c-1)(4c^2 - 2c - 1)= 0$.

Now, we know that $\cos(36º)$ isn’t -1 or 0.5 – yes yes, thank you sensei, a bit more than 0.8, we know – so we’ll need to solve the quadratic to find the number we want.

Let’s make completing the square easy by multiplying everything by 4: $16c^2 - 8c - 4 = 0$. That’s $(4c-1)^2 = 5$, so $4c-1 = \pm \sqrt{5}$ and $c = \frac{ 1 \pm \sqrt{5}}{4}$.

$c$ is positive, so the positive root is the one we want - and it’s $\frac{\phi}{4}$.

Clearly, 36º is not the only $x$ that satisfies the equation $\cos(4x) + \cos(x) = 0$. What are the others?

**Identity number 3** is $\cos(A) + \cos(B) = 2\cos\left(\frac{A+B}{2}\right) \cos\left(\frac{A-B}{2}\right)$.

In the case where $A=4x$ and $B=x$, this gives $2\cos\left(\frac{5}{2}x\right)\cos\left(\frac{3}{2}x\right) = 0$.

This is satisfied when $\cos\left(\frac{5}{2}x\right) = (2k+1)90º$ or $\cos\left(\frac{3}{2}x\right) = (2k+1)90º$.

The first of those gives $x = (2k+1)36º$, so $x$ can be 36º, 108º (which gives the negative root), 180º (-1), 324º (the positive root), and so on modulo 360º.

The second gives $x = (2k+1)60º$, so $x$ can also be 60º (0.5), 180º (-1), 300º (0.5), and so on modulo 360º.

I hope that helps!

- Uncle Colin

The post Ask Uncle Colin: an unexpected Golden Ratio appeared first on Flying Colours Maths.

]]>The post A Catriona Shearer Classic appeared first on Flying Colours Maths.

]]>(Image from Issue 10 of Chalkdust, a magazine for the mathematically curious.)

It’s a Catriona Shearer classic: there just doesn’t look like there’s enough information to solve it.

Spoiler: there is. And I’m going to spoiler it some more below the line.

First things first: let’s write down the information we have.

- There’s a Small regular hexagon with area 12 units.
- One of its vertices, A, is shared with a Huge Hexagon.
- Another vertex, C (two edges away) is shared with a Big Hexagon.
- Big Hexagon shares a vertex D, two edges away from C, with the Huge Hexagon.
- Big Hexagon shares another vertex E (two away from C but the other way) with a Medium Hexagon.
- The vertex F on Medium Hexagon adjacent to E is shared with Huge Hexagon, two edges away from A.

I don’t know that that helps immediately. Maybe a picture will?

It’s a Catriona Shearer puzzle. There’s *bound* to be a simple answer.

In particular, the hexagons are arranged haphazardly - where they *are* isn’t important. We can move them around, so long as we keep them all regular.

In particular, I can make it sorta-symmetrical by making two of the Big Hexagon’s edges partially coincide with the Huge hexagon.

Now it becomes clear: DEC is an equilateral triangle, and DFA is an equilateral triangle, so EF = AC.

AC, being a short diagonal of a hexagon, is $\sqrt{3}$ times as long as its edge - so the edges of Medium Hexagon are $\sqrt{3}$ times as long as those of Small Hexagon; its area is three times as big, so the area of the Medium hexagon is 36 units.

So that’s the answer… in the symmetric case. And presumably every case, but it feels a bit dissatisfying to leave it there, doesn’t it?

The triangle insight feels important, so let’s dim down the hexagons and put some triangles in their place.

With a bit of thought, we can find some congruent triangles! Angles FDE and ADC are equal, as are sides FD and DA; DE and DC are also equal to each other, so triangle FED is congruent to ACD - and AC = FE, which is what we wanted!

Like so many of Catriona’s puzzles, I enjoyed that one twice: first in finding *an* answer, and then in showing that it was *the* answer.

Did you tackle it any differently? I’d love to hear.

* Many thanks to @cshearer41 and @chalkdustmag for use of the puzzle.

The post A Catriona Shearer Classic appeared first on Flying Colours Maths.

]]>The post Ask Uncle Colin: how many zeros? appeared first on Flying Colours Maths.

]]>Dear Uncle Colin,

How many zeros are there on the end of $100!$? I worked it out to be 21, but the answer sheet says it’s 23 – and my calculator just gives an error message. What do you think?

- Maybe A Tutor Has Exact, Reasoned Response?

Hi, MATHERR, and thanks for your message!

I think the correct answer is… neither 21 nor 23!

I’ve seen students try to tackle this question, and the approach that seems obvious to most people is to work out the first few factorials. But, by the time they get to 12 or so, the numbers are becoming unmanageable, and it’s quite common to give up the hunt at that point.

However, some students use what they’ve got so far to spot a pattern: 5! is the first factorial that has a zero at the end, and 10! is the first with two zeros.

And, thinking about it, that makes sense: every time you multiply by 5, you’re going to add an extra 0 on the end1

I suspect you’ve got this far, and noted that multiplying by 100 must add two zeros rather than one, making a total of 21 added zeros.

What’s missing here is that there are 100 isn’t the only number that gives you two extra zeros. In fact, the rule is to add a zero for every multiple of 5, and an extra zero for every multiple of 252 – and if you took it to, say, 1000, a further zero for every multiple of every power of 5.

We can say that more neatly: every number has a unique prime factorisation of the form $2^{p_2}\times 3^{p_3} \times 5^{p_5} \times 7^{p_7} \times \dots$, where $p$ is a non-negative integer. For example, $15 = 2^0 \times 3^1 \times 5^1 \times 7^0 \times \dots$, with all the other powers being 0. Looked at like this, when you work out $(k!)$, every number that’s multiplied adds its $p_5$ zeros.

In this particular case, we have four numbers that are multiples of $5^2$, and 16 others that are multiples of $5^1$, making a total of 24 zeros.

Hope that helps!

- Uncle Colin

- You might want to mentally account for why the number, stripped of zeros, is always even.
- can you see why?

The post Ask Uncle Colin: how many zeros? appeared first on Flying Colours Maths.

]]>The post Completing the square appeared first on Flying Colours Maths.

]]>It’d be easier to complete the square if the $x$ term were even, so let’s double:

$2ax^2 + 2bx + 2c = 0$

It’s also be nicer if the $x^2$ term were a square, so let’s multiply by $2a$:

$4a^2x^2 + 4abx + 4ac = 0$

The first two terms are $(2ax)(2ax + 2b)$, which by difference of two squares, is $(2ax + b)^2 - b^2$:

$(2ax + b)^2 - b^2 + 4ac = 0$

Or better:

$(2ax + b)^2 = b^2 - 4ac$

Unsquare everything:

$2ax + b = \pm \sqrt{b^2 - 4ac}$

Rearrange:

$x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}$

Now, I know that won’t come as a surprise. However, there are two nuggets in doing it this way that I especially like:

- Making the first term a square and the second term even hugely simplifies the process of completing the square (who among us has not got confused by the “uh… it’s $a\left(x - \frac{b}{2a}\right)^2 - \frac{b^2}{4a^2}$, I think…?” process?).
- Dealing with the first two terms as a difference of two squares is probably unnecessary, but a link I hadn’t drawn before.

The post Completing the square appeared first on Flying Colours Maths.

]]>The post Ask Uncle Colin: A Pair Of Toy Trucks appeared first on Flying Colours Maths.

]]>Dear Uncle Colin,

I have an exam question I don’t understand! There’s a toy truck of mass 5kg attached (by a rod) to another truck of mass 2kg on a slope at 10 degrees to the horizontal. The resistances to motion are 8N and 6N, respectively, and the whole thing is pulled up the slope by a string. The question says to show that the rod is always in tension so long as the trucks move up the slope. What’s your approach?

Toys Easily Negotiate Slope In Our Nursery

Hi, TENSION, and thanks for your message!

The first thing I would do is draw a picture. It would probably be a messy picture, like this one.

Since the trucks are moving up the plane, the resistance forces act down it. There’s an equal-and-opposite force in the coupling which I’ve drawn as a tension, but could be a thrust (if so, $T_c$ will wind up negative, and that’s perfectly ok in a rod. In a string, it would be a problem).

I like to think of a grid with this kind of question, with lines parallel and perpendicular to the surface. In fact, by turning the page, I can draw it like this:

The two weights are the only ones off of the grid - and I only really care about the ‘horizontal’ components of those (that is, parallel to the plane). Those are $2g \sin(10º)$ and $5g \sin(10º)$, respectively.

Then I can write down equations of motion for the parts of the system, and the system as a whole:

- Upper truck: $T_s - T_c - 8 - 5g\sin(10º) = 5a$
- Lower truck: $T_c - 6 - 2g\sin(10º) = 2a$
- System: $T_s - 14 - 7g \sin(10º) = 7a$

The *acceleration* could be in either direction, but as long as the *velocity* is upwards, these equations hold true.

Starting with the system as a whole, $a = \frac{T_s}{7} - 2 - g\sin(10º)$.

Substituting this into the lower truck equation gives: $T_c - 6 - 2g\sin(10º) = 2\left( \frac{T_s}{7} - 2 - g\sin(10º)\right)$, or $T_c = \frac{2}{7} T_s + 2$

Since $T_s \ge 0$ (it’s a tension in a string), $T_c \ge 2$ and is in tension as long as the motion is uphill.

Hope that helps!

- Uncle Colin

The post Ask Uncle Colin: A Pair Of Toy Trucks appeared first on Flying Colours Maths.

]]>The post Dictionary of Mathematical Eponymy: Volder’s algorithm appeared first on Flying Colours Maths.

]]>It’s not, typically, the way that the Mathematical Ninja would (find an angle nearby and adjust using heuristics), but it’s not all that far away. The method a calculator typically uses is known as CORDIC1 or - at least for the purposes of this dictionary, Volder’s algorithm.

The principle of Volder’s algorithm is to rotate a vector on the unit circle by progressively smaller angles in either direction until it reaches the angle you’re interested in.

So far, so obvious - that’s basically what the Ninja does.

The clever bit is picking angles - and the corresponding rotation matrix - so that the calculation is straightforward.

Your standard angular rotation matrix looks like this: $\mattwotwo{\cos(\Theta)}{-\sin(\Theta)}{\sin(\Theta)}{\cos(\Theta)}$ - but that rather begs the question. However, there’s a nice pair of identities that helps here:

- $\sin(\theta) \equiv \frac{\tan(\theta)}{\sqrt{1 + \tan^2(\theta)}}$
- $\cos(\theta) \equiv \frac{1}{\sqrt{1 + \tan^2(\theta)}}$

This turns the rotation matrix into $\frac{1}{\sqrt{1+\tan^2(\theta)}} \mattwotwo{1}{-\tan(\theta)}{\tan(\theta)}{1}$

And if we pick $\theta$ so that $\tan(\theta)$ is a (non-positive integer) power of 2, we can make use of the fact that computers can multiply by such numbers almost instantaneously using bit shifts. And in particular, if we start by moving by $\arctan\left( 2^0 \right)$ in the correct direction, then $\arctan\left( 2^{-1} \right)$, and so on, we can get as close as we like to the angle we want - and, probably the neatest thing - the factors in front of the rotation matrix, the $\frac{1}{\sqrt{1+\tan^2(\theta)}}$s, are the same set of values, no matter what angle we pick.

The only wrinkles, then, are:

- keeping track of how far you’ve rotated so far (which is just a case of working out ahead of time what $\arctan\left(2^{-k}\right)$ is for as many values as you fancy using);
- keeping track of the product of the constant factors in front of the matrix - which, again, you can work out ahead of time.

At the end of the series of (very quick to compute) rotations, the vector you wind up with is $\colvectwo{\cos(\theta)}{\sin(\theta)}$, or as close to it as you could possibly want.

The motivation for Volder’s algorithm came from aircraft manufacturing: the B-58 bomber’s navigation computer relied on an analogue resolver, and needed to be replaced by an accurate electronic version. Seeing as this was the 1950s and computers were generally comparable in size to planes2, hardware efficiency and speed were of the essence - and a shift-and-add system like this hits both of the goals nicely.

Variations on it were soon implemented for other useful functions, such as square roots, logarithms and hyperbolic functions, and formed the basis for hand-held calculation devices for many years.

Volder is another largely mysterious mathematician. He was born in Fort Worth, Texas in 1924 and graduated from Texas Technological College in 1949 before moving into aircraft equipment design, at first in Wisconsin and then back in Texas.

He died in Yorba Linda, California, in 2013.

- CO-ordinate Rotation DIgital Computer
- and just as prone to crashing

The post Dictionary of Mathematical Eponymy: Volder’s algorithm appeared first on Flying Colours Maths.

]]>The post Ask Uncle Colin: integrating a trigonometric product appeared first on Flying Colours Maths.

]]>Dear Uncle Colin,

I need to figure out $\int \cos^3(2t) \sin^5(2t) \dt$ and I’m… just going round in circles. So to speak. What do you suggest?

- Doing Integration’s Really A Chore

Hi, DIRAC, and thanks for your message!

It’s very easy to end up going around in circles on these - the trick is to figure out the simplest transformation that turns your integral into something you *do* have the tools for.

I can see a fairly straightforward way to tackle this.

Products of powers of sines and cosines only really get *nice* when you wind up with a single sine or cosine multiplied by something horrible. In this case, writing the integral as $\int \cos(2t) \cos^2(2t) \sin^5(2t) \dt$ and replacing the cosine-squared with $1 - \sin^2(2t)$ gives:

$\int \cos(2t) \left[ \sin^5(2t) - \sin^7(2t)\right]\dt$

At first blush, that looks uglier - but both of the components are function-derivative and you end up with $\frac{1}{12}\sin^6(2t) - \frac{1}{16}\sin^8(2t) + C$.

Hope that helps!

- Uncle Colin

The post Ask Uncle Colin: integrating a trigonometric product appeared first on Flying Colours Maths.

]]>The post A Puzzle Full of Nines appeared first on Flying Colours Maths.

]]>This AIME problem is fun: pic.twitter.com/DhbviTqnqr

— Benjamin Leis (@benjamin_leis) February 2, 2020

In case you can’t read that, we need to find the sum of the digits in $N = 9 + 99 + 999 + 999\dots999$, where the last number consists of 321 consecutive nines.

As usual, I’ll let you pause to think about it here and post spoilers below the line.

It feels like a geometric sequence - and it sort of is, although it took me a while to spot it. It also looks like it’s related to the decimal expansion of fractions, although that turned out to be a dead-end.

The trick (for me, at least), is to write each term as $10^k - 1$.

Then we’re looking at $N = \sum_{k=1}^{321} \left( 10^k - 1\right)$.

We can split that into two sums: a geometric sequence and $321\times1$. We *could* bring out the formula for that, but why would we? It’s going to be a string of 321 ones with a zero at the end.

From that, we need to subtract 321 - and we only really care about the last four digits here: $1110 - 321 = 0789$.

So, we’ve still got 318 ones in our string (the digits of which sum to 318), followed by 0789 (the digits of which sum to 24), making a total of 342.

The number $N$ is a multiple of 9, so its digits sum to a multiple of 9. It’s worth checking that our answer makes sense: is 342 a multiple of 9? Well, its digits sum to 9, so it looks plausible! (It’s $38\times 9$, the Ninja murmurs in their sleep).

It doesn’t mean we definitely have the right answer - but it increases our confidence slightly; had we got something that wasn’t a multiple of 9, we’d know we had it wrong.

I enjoyed that puzzle. Did you tackle it a different way?

The post A Puzzle Full of Nines appeared first on Flying Colours Maths.

]]>The post Ask Uncle Colin: How do I stretch my students? appeared first on Flying Colours Maths.

]]>Dear Uncle Colin,

I want to stretch my Year 12 Further Maths class - what extra-curricular topics would you recommend?

Something To Really Engage Their Creative Reasoning

Hello, STRETCH, and thanks for your message!

How excellent to be looking beyond the curriculum for ways to engage and develop your young mathematicians! I have several suggestions:

**Basic group theory**.~~It used to be that basic group theory was part of some of the Further Maths curriculums, but no longer (which is understandable, but sad)~~*Thanks to Mark Thornber for pointing out that EdExcel's FP2 and OCR's Additional Pure have some group and number theory). There are some nice, accessible results that can be understood with modular arithmetic.***Number theory**. Building on the group theory, number theory starts off quite accessible, but goes*really*deep – and the benefits to a student’s understanding of proof are off the charts.**Mathematical ninjary**. This is, I have to concede, 80% showing-off and 20% actually useful - but it a) makes you a more convincing mathematician if you can mentally work out sums that look hard and b) shores up all sorts of approximation methods. But yeah, it’s mainly showing off.**Continued fractions**. These are my latest mini-obsession. They take a while to make sense of, but there are all sorts of pleasing results in easy reach and again, plenty of depth.**Reading and writing**. Maths isn’t*just*about doing. It’s also about reading, processing and communicating. Have the students summarise Chalkdust articles, or justify their favourite theorem, or explain something cool in Geogebra?**Coding**. Don’t be afraid of projects that require some computer power behind them. Good programming habits open a lot of doors!

I hope there’s something useful in there! Good luck.

- Uncle Colin

* Edited 2020-09-27 to correct an assertion about the new syllabus.

The post Ask Uncle Colin: How do I stretch my students? appeared first on Flying Colours Maths.

]]>The post Primes or not? appeared first on Flying Colours Maths.

]]>Prime or not prime? No calculators allowed!

a. 23567897614^2 - 1

b. 34564344^3 -1

c. 76543556556625731

d. 345643554^{10} - 169— Jase (@jase_jwanner) August 27, 2016

I shall give you a moment to ponder these, and put my spoiler below the line.

The first and last of these are, if you look at them the right way, completely obvious: the two numbers in $23567897614^2 - 1$ are both squares, and what you have is a difference thereof, so this is clearly a composite number. (In fact, a moment’s thought tells you it’s a multiple of 5.)

Similarly, $345643554^{10} - 169$ is a difference of two squares, so it’s composite.

Less obviously, but still similarly, $34564344^3 -1$ is a difference of two cubes, and $x^3 - 1 = (x-1)(x^2 + x + 1)$ - so this is also composite.

Now, $76543556556625731$ is the interesting one. From the context of the tweet, I would *imagine* it’s going to be composite, because there’s no simple way to show that it’s prime.

There are no obvious squares nearby, so my next trick from the bag is to look at small factors.

And we’re in luck! Summing the digits gives 81, which - being a multiple of 9 - tells us that $76543556556625731$ is a multiple of 9.

Did you tackle them any othe ways? Let me know in the comments!

The post Primes or not? appeared first on Flying Colours Maths.

]]>