Evaluates the function on the given x value.
x
num evaluateOn(double x) { const evaluator = ExpressionParser(); return evaluator.evaluateOn(function, x); }