I have fence posts placed in a line and, as part of my spouse’s birthday celebrations, I wish to paint them using three different colours red, white and blue in such a way that no adjacent fence posts have the same colours. (This allows the possibility of using fewer than three colours as well as exactly three.) Let be the number of ways (possibly zero) that I can paint them if I paint the first and last post red and let be the number of ways that I can paint them if I paint the first post red but the last post either of the other two colours. Explain why and find . Hence find the value of for all .
Prove, by induction, that
Find the number of ways of painting fence posts (where ) placed in a circle using three different colours in such a way that no adjacent fence posts have the same colours.