It's easy to calculate interest on a fixed principal. If you have for example $1000 deposit on your savings account and the rate is 0.25% compounded every whatsoever and you want to know how much is the interest after some time then just use the formula for compound interest.
But what if you make irregular deposits and withdrawals? Say after a month, you deposit $500, then after another month you deposit $200, then after two months you withdraw $300, how do you calculate interest after a certain period of time?? What happens to the original principal?? Or is it like you compute compound interest for each deposit separately then get their sum? But what about the withdrawals???