FV = P × [(1 + r)^n - 1] / r × (1 + r)
Tax Calculation: Tax is applied to the gains (maturity amount - total invested) based on your specified tax rate.