Parses simple mathematical formulas