If $f(x)=p x+q$ and $f(f(f(x)))=8 x+21$, and if $p$ and $q$ are real numbers, then $p+q$ equals
(A) 2
(B) 3
(C) 5
(D) 7
(E) 11
Solution

Using $f(x)=p x+q$, calculate the following:

$$
\begin{aligned}
f(f(x)) & =f(p x+q) \\
& =p(p x+q)+q \\
& =p^{2} x+p q+q
\end{aligned}
$$

and

$$
\begin{aligned}
f(f(f(x))) & =f\left(p^{2} x+p q+q\right) \\
& =p\left(p^{2} x+p q+q\right)+q \\
& =p^{3} x+p^{2} q+p q+q
\end{aligned}
$$

Equate this to $8 x+21$ to find $p=2$ and $q=3$.

Thus, $p+q=5$.

ANSWER: (C)

#