How to calculate income tax deductions