Simplifying expressions with square roots and variables