The problem is as shown in the attatchment.
The relevant equations are also given in the attatchment.
The Attempt at a Solution
My problem is how to adapt the given formula in order to find the sum of the function k(40-r)
Do i use the formula for 1 to 40, then 1 to 20 and subtract?
Even just a hint in the right direction would be useful. This sorta stuff has never been my strong point.