Mathematics of finance, compound interests and annuities