<?xml version="1.0" encoding="UTF-8" ?>
  <resource>
  <id>8867</id>
  <path>/www/nrich/html/content/id/8867/</path>
  <resourceTypeID>1</resourceTypeID>
  <last_published>0000-00-00T00:00:00</last_published>
  <indexXML>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;mdoxml version=&quot;1.0&quot;&gt;&lt;div class=&quot;latex&quot;&gt;
&lt;h3&gt;An Introduction to Graph Colouring&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;In this article we&amp;#39;ll discuss colouring a &lt;em&gt;graph&lt;/em&gt;. Not the bar chart type, but the kind of graph also called a &lt;em&gt;network&lt;/em&gt; which might be covered in A-Level decision maths. For a good introduction try the problem &lt;a href=&quot;https://nrich.maths.org/8257&quot;&gt;Simply Graphs&lt;/a&gt;, which introduces you to different kinds of graph. This article
encourages you to do some thinking as you read; so go and find paper, and something to draw and colour with. If you have red and blue that would be best!&lt;/p&gt;
&lt;h4&gt; &lt;/h4&gt;
&lt;h3&gt;Complete Graphs&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;For now we&amp;#39;re only interested in &lt;em&gt;complete graphs&lt;/em&gt; which are quite special. An easy way to draw a complete graph is to put a number of vertices roughly in a circle and connect each one to every other with an edge. Below is a complete graph with 5 vertices.&lt;/p&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;mdo:image src=&quot;K5.png&quot; style=&quot;height: 226px; width: 250px;&quot;&gt;&lt;/mdo:image&gt;&lt;/div&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Try to draw complete graphs with 3, 4 and 6 vertices. It gets a bit tedious with larger numbers! How many different kinds of complete graphs are there? Well, despite many different ways of drawing each one, if two complete graphs have the same number of vertices they can be moved to look identical. Sometimes we say they&amp;#39;re &lt;em&gt;isomorphic&lt;/em&gt; but it&amp;#39;s often
easier to think of them genuinely the same. For this reason we call the complete graph on $n$ vertices $K_n$. That means we have a picture of $K_5$ above, for example.&lt;/p&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;&lt;strong&gt;Exercise 1.&lt;/strong&gt; Try to come up with properties of $K_n$. How many edges does it have? What graphs can you find inside it?&lt;br&gt;&lt;/br&gt;
 &lt;/p&gt;
&lt;h3&gt;Graph Colouring&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;A good drawing of a complete graph can be quite pretty but mathematicians tend to have an eye for beauty, and &lt;a href=&quot;http://en.wikipedia.org/wiki/Frank_P._Ramsey&quot;&gt;Frank Ramsey&lt;/a&gt; started a whole branch of graph theory based on colouring the edges of complete graphs. With colour they&amp;#39;ll look even better! This article is an introduction to Ramsey Theory, which
involves making structures such as graphs large enough that &amp;#39;nice&amp;#39; properties occur. We&amp;#39;re using colours to represent our &amp;#39;nice&amp;#39; properties.&lt;/p&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;We&amp;#39;ll start off simply. Take two colours, say blue and red. Colour the edges of a few complete graphs like below. What do you notice? Are there any &lt;em&gt;monochromatic triangles&lt;/em&gt;? That means triangles with all the sides in one colour. Draw some big ones and colour them. Do you always make a triangle?&lt;/p&gt;
&lt;p style=&quot;line-height: 150%; text-align: center;&quot;&gt;&lt;mdo:image src=&quot;K4.png&quot; style=&quot;height: 216px; width: 250px;&quot;&gt;&lt;/mdo:image&gt;&lt;mdo:image src=&quot;K6.png&quot; style=&quot;width: 250px; height: 227px;&quot;&gt;&lt;/mdo:image&gt;&lt;/p&gt;
&lt;p&gt;The question we want to answer is this:&lt;/p&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;&lt;em&gt;&quot;How big must a complete graph be to make sure that whenever we colour the edges blue or red, a monochromatic triangle is present?&quot;&lt;/em&gt;&lt;/p&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;It&amp;#39;s not even obvious that such a number exists, because maybe for some special really really enormous complete graphs we can colour them without making a monochromatic triangle!&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
In fact we can prove quite easily that whenever a $K_6$ has its edges coloured red or blue (we&amp;#39;ll call this a 2-colouring), we have a monochromatic triangle. Since a $K_6$ is inside every $K_n$ for $n\geq 6$ we&amp;#39;ll have shown that 2-colouring any large complete graph must give a monochromatic triangle!&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
&lt;strong&gt;Proof.&lt;/strong&gt; Pick any vertex of the $K_6$, call it $v$. It has five neighbours each connected to it by an edge coloured blue or red. Here&amp;#39;s the clever bit: three of these edges &lt;em&gt;must&lt;/em&gt; be the same colour. Can you see why? Think about how many are red and then the rest must be blue. Anyway, since we don&amp;#39;t really mind what colour our triangle is we can redraw the graph with the
colours swapped if necessary, and assume that $v$ has three neighbours connected by blue lines called $x$, $y$, and $z$. There&amp;#39;s a picture below.&lt;/p&gt;
&lt;p style=&quot;line-height: 150%; text-align: center;&quot;&gt;&lt;mdo:image src=&quot;vxyz.png&quot; style=&quot;height: 186px; width: 250px;&quot;&gt;&lt;/mdo:image&gt;&lt;/p&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Now what of the edges between $x$, $y$, and $z$? If any of them are blue, e.g. from $x$ to $y$, then we have a blue triangle, made with $v$. If none of them are blue, all of them are are red; so that $x$, $y$, and $z$ make a red triangle. We &lt;em&gt;must&lt;/em&gt; have one of the two cases, hence a monochromatic triangle. Clever don&amp;#39;t you think? $\square$&lt;br&gt;&lt;/br&gt;
 &lt;/p&gt;
&lt;h3&gt;Going Further&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Ramsey Theory doesn&amp;#39;t stop there however! We have more work to do which a little extra notation will make easier. When we proved that a 2-colouring of $K_6$ must give a monochromatic triangle, we showed that $R(3,3) &amp;amp;lt;= 6$. What does that mean? Well, we use $R(s, t)$ to mean the smallest size of a complete graph that when 2-coloured, must give either a blue $K_s$ or
a red $K_t$. Since a $K_3$ &lt;em&gt;is&lt;/em&gt; a triangle, we know that all 2-coloured $K_n$ for $n \geq 6$ have a blue $K_3$ or a red $K_3$. Thus $R(3,3) \leq 6$. But what about coloring $K_5$?&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
&lt;strong&gt;Exercise 2.&lt;/strong&gt; Try to find a 2-colouring of $K_5$ without a triangle. Is it possible? Does the argument we used for $K_6$ in the proof above work for $K_5$? Why? Why not? What does this mean for the value of $R(3,3)$?&lt;br&gt;&lt;/br&gt;
 &lt;/p&gt;
&lt;h3&gt;What Next?&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Keep reading if you want to learn how to generalise these ideas. Mathematicians are always searching for the next good question. How about one of the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Is there a way I can force a 2-colouring of a $K_n$ to contain a monochromatic square?&lt;/li&gt;
&lt;li&gt;How about finding monochromatic $K_4$s?&lt;/li&gt;
&lt;li&gt;What about using three colours?&lt;/li&gt;
&lt;/ul&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Often it&amp;#39;s important to ask the right question. Can you see how an answer to the second one would help the first? Remember, what kind of graphs do $K_4$s contain?&lt;/p&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;To help work out what happens if we look for $K_4$s we might want to consider a simpler case first. Can we find $R(3,4)$? This means we are looking to force either a blue triangle (a $K_3$) or a red $K_4$. We&amp;#39;ll adapt and extend the method use in the first proof.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
&lt;strong&gt;Theorem.&lt;/strong&gt; A 2-colouring of a $K_{10}$ always contains a blue $K_3$ or a red $K_4$.&lt;br&gt;&lt;/br&gt;
&lt;strong&gt;Proof.&lt;/strong&gt; Let&amp;#39;s look at a blue/red coloured $K_{10}$. Pick a vertex and call it $v$, it has nine neighbours. Consider the edges from $v$, and we have a new &amp;#39;clever bit&amp;#39;. Either&lt;/p&gt;
&lt;ol start=&quot;1&quot; style=&quot;list-style-type: lower-roman;&quot;&gt;
&lt;li&gt;4 of them are blue, joined to vertices we&amp;#39;ll call $w$, $x$, $y$, and $z$.&lt;/li&gt;
&lt;li&gt;6 of them are red, so there&amp;#39;s a 2-coloured $K_6$ attached to $v$ by red edges.&lt;/li&gt;
&lt;/ol&gt;
We&amp;#39;ll do each case separately.
&lt;ol start=&quot;1&quot; style=&quot;list-style-type: lower-roman;&quot;&gt;
&lt;li&gt;If any of the edges between $w$, $x$, $y$, and $z$ are blue we have a blue triangle (with $v$), and if not, then we have a red $K_4$ on those vertices.&lt;/li&gt;
&lt;li&gt;We know that the $K_6$ must have a blue triangle (then we&amp;#39;re happy) or a red one. If it&amp;#39;s the red, then the extra edges connecting it to $v$ are also red, so in our $K_{10}$ we have a red $K_4$. Lovely!$\square$&lt;/li&gt;
&lt;/ol&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;So is $R(3,4)=10$? Don&amp;#39;t get carried away - we&amp;#39;ve merely shown $R(3,4)\leq 10$, in fact it is 9. Try to prove that!&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;h3&gt;Niggling Doubts&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Things are progressing nicely, we&amp;#39;ve been able to adapt our methods to find larger $R(s,t)$ numbers. But might we run into trouble as we get larger? What about finding a monochromatic  $K_{10}$ inside a $K_{971346987}$? How will we cope? &lt;em&gt;More generalising&lt;/em&gt;, that&amp;#39;s how.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
&lt;strong&gt;Ramsey&amp;#39;s Theorem&lt;/strong&gt; states that $R(s,t)$ exists for any natural numbers $s$ and $t$. This general version of what we were doing earlier requires some of the same ideas, coupled with &lt;em&gt;mathematical induction&lt;/em&gt; which is a powerful technique!&lt;br&gt;&lt;/br&gt;
&lt;strong&gt;Proof.&lt;/strong&gt; Starting with some simple cases, we can easily show that $R(s,2)=s$ and $R(2,t)=t$. Remember that a $K_2$ is just an edge joining two vertices so if any of the edges in a $K_s$ are red, we have a red $K_2$, and if not then they&amp;#39;re all blue so we have a blue $K_s$. The other one is the same because $R(s,t) = R(t,s)$ by swapping the colours.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
What about larger $s$ and $t$? In the style of induction we assume that we know the numbers $R(s-1,t)=m$ and $R(s, t-1)=n$. Well how did the $R(3,4)$ case work? We wanted enough edges at vertex $v$ to be a given colour that we could use our previous knowledge that $R(3,3)=6$. Well what about a $K_{m+n}$? Then vertex $v$ has $m+n-1$ edges attached so either&lt;/p&gt;
&lt;ol start=&quot;1&quot; style=&quot;list-style-type: lower-roman;&quot;&gt;
&lt;li&gt;$m$ are blue, so a $K_m$ is attached to $v$ by blue edges&lt;/li&gt;
&lt;li&gt;$n$ are red, so a $K_n$ is attached to $v$ by red edges&lt;/li&gt;
&lt;/ol&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;In case i. we know by induction that the $K_m$ has a blue $K_{s-1}$ or a red $K_t$ (remember we chose $m$ to be $R(s-1,t)$). If it&amp;#39;s the blue $K_{s-1}$ then together with $v$ we have a blue $K_s$, and if it&amp;#39;s the red $K_t$ we&amp;#39;re happy anyway. Can you convince yourself that case ii. is similar and argue that one yourself?$\square$&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Notice that we never actually &lt;em&gt;found&lt;/em&gt; any $R(s,t)$ values exactly except when one of $s=2$ or $t=2$. We simply showed that given $s$ and $t$, for some &lt;em&gt;large enough&lt;/em&gt; $n$, every $K_n$ that is 2-coloured has a blue $K_s$ or a red $K_t$. This means that $R(s,t)$ must exist, and with some work we could give an upper bound on what value it could have - but we haven&amp;#39;t
found it.&lt;/p&gt;
&lt;h3&gt;Difficult Questions&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Ramsey&amp;#39;s Theorem shows that $R(s,t)$ exists, but how big is it? We were able to find $R(3,3)$ exactly, but only a bound on $R(3,4)$. It requires more work to find the exact value. What about $R(4,4)$ and larger? In fact it is&lt;em&gt; &lt;/em&gt;&lt;em&gt;extremely&lt;/em&gt; hard to find these numbers. At this point in time even $R(5,5)$ is unknown! We know it&amp;#39;s between $43$ and
$49$ but we&amp;#39;re not sure where. A very distingushed graph theorist &lt;a href=&quot;http://en.wikipedia.org/wiki/Paul_Erd%C5%91s&quot;&gt;Paul Erdős&lt;/a&gt; once said of $R(5,5)$ and $R(6,6)$ that: &lt;/p&gt;
&lt;blockquote&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Suppose aliens invade the earth and threaten to obliterate it in a year&amp;#39;s time unless human beings can find the Ramsey number for red five and blue five. We could marshal the world&amp;#39;s best minds and fastest computers, and within a year we could probably calculate the value. If the aliens demanded the Ramsey number for red six and blue six, however, we would have no
choice but to launch a preemptive attack.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h3&gt;Possible Extensions&lt;/h3&gt;
&lt;p style=&quot;line-height:150%;&quot;&gt;Though you should have already learned a lot, this article only scratches the surface of some simple problems in Ramsey Theory. There are extensions of this work using more than two colours and graphs with infinitely many vertices. There are applications of these results too! Topics in analysis and number theory make use of the ideas here, with colours
changed for properties of functions and numbers.&lt;/p&gt;
&lt;h3&gt;Answers&lt;/h3&gt;
&lt;ol class=&quot;boldNumberedList&quot; start=&quot;1&quot;&gt;
&lt;li&gt;
&lt;p style=&quot;font-weight:normal;&quot;&gt;$K_n$ has $n \choose k$ edges as each vertex is joned to every other. That&amp;#39;s $\frac{n(n-1)}{2}$ edges in total. Any graph (without multiple edges or loops) on $n$ or fewer vertices is a subgraph of $K_n$. Can you think why?&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p style=&quot;font-weight:normal;&quot;&gt;There is a 2-colouring of $K_5$ which doesn&amp;#39;t contain a monochromatic triangle, I hope you found it. An example is below.&lt;/p&gt;
&lt;p style=&quot;font-weight: normal; text-align: center;&quot;&gt;&lt;mdo:image src=&quot;K5_col_cropped.png&quot; style=&quot;height: 190px; width: 200px;&quot;&gt;&lt;/mdo:image&gt;   &lt;/p&gt;
&lt;p style=&quot;font-weight:normal;&quot;&gt;This means the value of $R(3,3)$ is actually 6. Great!&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
&lt;br&gt;&lt;/br&gt;&lt;/mdoxml&gt;</indexXML>
  <solutionXML/>
  <noteXML/>
  <clueXML/>
  <canonXML/>
  <end_user_role>2</end_user_role>
  <difficulty>3</difficulty>
  <keystage1>0</keystage1>
  <keystage2>0</keystage2>
  <keystage3>0</keystage3>
  <keystage4>0</keystage4>
  <keystage4plus>0</keystage4plus>
  <title>An Introduction to Graph Colouring</title>
  <description></description>
  <spec_group>Decision Mathematics and Combinatorics
    <specifier>Combinatorics</specifier>
  </spec_group>
  <spec_group>Decision Mathematics and Combinatorics
    <specifier>Networks/Graph Theory</specifier>
  </spec_group>
</resource>