CEMC Banner

Problem of the Week
Problem E and Solution
Painting Faces

Problem

A cube has side length \(n\), where \(n\) is a positive integer. Exactly three faces, which meet at a corner, are painted purple. The cube is then cut into \(n^3\) smaller cubes with side length \(1\). If exactly \(125\) of these smaller cubes have no faces painted purple, then determine the value of \(n\).

Solution

Solution 1

We label the faces painted purple as \(A\), \(B\), and \(C\). We know that there are \(n^3\) smaller cubes of side length \(1\). To determine the number of smaller cubes with all faces unpainted, we can subtract the number of cubes with some purple faces from the total number of cubes. Face \(A\) has dimensions \(n\) by \(n\), and so contains \(n^2\) unit cubes with some purple. Ignoring the area on face \(B\) which includes the smaller cubes also on face \(A\), the remainder of face \(B\) has dimensions \(n\) by \((n-1)\), and so contains \(n\times (n-1)\) more unit cubes with some purple. Ignoring the area on face \(C\) which includes the smaller cubes also on face \(A\) or on face \(B\), face \(C\) has dimensions \((n-1)\) by \((n-1)\), and so contains \((n-1)(n-1)\) more unit cubes with some purple.

The number of unpainted cubes is thus, \(n^3-n^2-n(n-1)-(n-1)(n-1)\). We can simplify this as \[n^3-n^2-n(n-1)-(n-1)(n-1)=n^2(n-1)-n(n-1)-(n-1)(n-1)\]

Each term in this expression contains a common factor of \((n-1)\), so the expression simplifies to \((n-1)(n^2-n-(n-1))=(n-1)(n^2-2n+1)\). This further simplifies to \((n-1)^3\). If the solver pauses here to think about this, if the unit cubes on face \(A\) then face \(B\) and finally face \(C\) are removed, we are left with a cube with side length \((n-1)\), and so \((n-1)^3\) unit cubes.

So, \((n-1)^3=125\), the actual number of unpainted cubes.

Taking the cube root, \(n-1=5\), and so \(n=6\) follows.

Solution 2

This solution uses the factor theorem which is generally taught in Grade 12.

As in Solution 1, the number of unpainted cubes is \(n^3-n^2-n(n-1)-(n-1)(n-1)\). Setting this equal to \(125\), we have \[\begin{aligned} n^3-n^2-n(n-1)-(n-1)(n-1)&=125\\ n^3-n^2-n^2+n-n^2+2n-1&=125\\ n^3-3n^2+3n-126&=0 \end{aligned}\] Let \(f(n)=n^3-3n^2+3n-126\).

When \(n=6\), \(f(6)=6^3-3(6^2)+3(6)-126=216-108+18-126=224-224=0\).

Since \(f(6)=0\), \((n-6)\) is a factor of \(f(n)\).

After long division (or synthetic division), we find \(f(n)=(n-6)(n^2+3n+21)\).

Since \(n^2+3n+21=0\) has no real solution, we know that \(n=6\) is the only real solution to \(n^3-3n^2+3n-126=0\).

Therefore, \(n=6\).