It is not difficult to see that the optimal solution for the rod cutting problem is determined by the recurrence:
$R(n) = max_{0<=i<= n} (R(n-i) + p[i])$.
$R(0) = 0$
We can see that a bottom-up dynamic programming approach will be easier here, starting from n = 1. The table is filled below, step-by-step.
$R(1) = max(R(0) + p[1]) = 1$
$R(2) = max(R(0) + p[2], \ R(1) + p[1]) = max(5, 1+1) = 5$.
$R(3) = max(R(0) + p[3], R(1) + p[2], R(2) + p[1]) = max(8, 1+5, 5 + 1) = 8$.
| | n = 1 | n = 2 | n = 3 | n = 4 | n = 5 | n = 6 | n = 7 |
| R(n) | 1 | 5 | 8 | | | | |
$R(4) = max(R(0) + p[4], R(1) + p[3], R(2) + p[2], R(3) + p[1]) = max(9, 1+8, 5 + 5, 8+1) = 10$
| | n = 1 | n = 2 | n = 3 | n = 4 | n = 5 | n = 6 | n = 7 |
| R(n) | 1 | 5 | 8 | 10 | | | |
$R(5) = max(R(0)+p[5], R(1) + p[4], R(2) + p[3], R(3) + p[2], R(4) + p[1]) = max (10, 1+9, 5+8, 8+5, 10+1) = 13$.
| | n = 1 | n = 2 | n = 3 | n = 4 | n = 5 | n = 6 | n = 7 |
| R(n) | 1 | 5 | 8 | 10 | 13 | | |
$R(6) = max(R(0) + p[6], R(1) + p[5], R(2) + p[4], R(3) + p[3], R(4) + p[2], R(5) + p[1]) = max(17, 1+10, 5+9, 8+8, 10+5, 13 + 1) = 17$
| | n = 1 | n = 2 | n = 3 | n = 4 | n = 5 | n = 6 | n = 7 |
| R(n) | 1 | 5 | 8 | 10 | 13 | 17 | |
$R(7) = max(R(0) + p[7], R(1) + p[6], R(2) + p[5], R(3) + p[4], R(4) + p[3], R(5) + p[2], R(6) + p[1])=$
$ max(18, 1+17, 5+10, 8+8, 13+5, 17+1) = $
$ max(18, 18, 15, 16, 18, 18)$.
Thus $R(7) = 18$.
We see that $R(7)$ is obtained by four different values of 18. Option D cannot be correct as split (2, 3, 2) produces an optimal solution, which can be identified using the calculations above.
Therefore, only options A and C are correct.