If I feel unhappy, I do mathematics to become happy. If I am happy, I do mathematics to keep happy.
or simply: