The 51 is got from adding up the balances. This will almost never equal the sum o f the spends.
Suppose you had 5 rs and you made 5 spends of 1 rs each. Your table would look like this.
Capital = 5 rs
Spend | Balance
1 | 4
1 | 3
1 | 2
1 | 1
1 | 0
============
5 | 10 (sum of spends to sum of balances)
As I said at the beginng, the 51 is the sum of the balances, which could have many values