Streamlined the Equation class by precomputing the Regex patterns once.