Simplifying numerical expressions involving integers