I'm a software developer, trying to write a simple formula for the following:
A person is tested and given a score (out of 100, but irrelevant). The number of criteria they fail adjusts their score as follows:
1st failed field = -5
2nd failed field = -10
3rd failed field = -15
4th failed field = -20
5th failed field = -25
These adjustments are cumulative, so if you fail 3 fields your score is adjusted by -30; 4 fails and you get -50.
So, the result is:
1 = -5
2 = -15
3 = -30
4 = -50
5 = -75
First thing in the morning I'm struggling to figure out the formula for this... I thought the answer was something like:
n^2 - ((n-1)^2 - ((n-2)^2 - ...
But it's the recursion that I can't figure out how to express correctly.
Edit:
OK, I think I got it as:
(0.5 * (n + 1)) * n * 5