Significant updates to mathtools