- (a) Use the standard results for \(\sum _ { r = 1 } ^ { n } r ^ { 2 }\) and \(\sum _ { r = 1 } ^ { n } r ^ { 3 }\) to show that, for all positive integers \(n\),
$$\sum _ { r = 1 } ^ { n } r ^ { 2 } ( r + 1 ) = \frac { 1 } { 12 } n ( n + 1 ) ( n + 2 ) ( a n + b )$$
where \(a\) and \(b\) are integers to be determined.
(b) Given that
$$\sum _ { r = 5 } ^ { 25 } r ^ { 2 } ( r + 1 ) + \sum _ { r = 1 } ^ { k } 3 ^ { r } = 140543$$
find the value of the integer \(k\).