else {
if (parser.containsVariables(equationParts.get(0), vars)) {
equation = equationParts.get(0);
ConsCell temp = parser.run(parser.preProcess(equationParts.get(1)));
if (temp.getCarType() != ConsType.NUMBER || temp.length() != 1)
throw new UndefinedResultException("The NumericalSolver requires that the equation contain only one variable.", null);
answer = (BigDec) temp.getCar();
}
if (parser.containsVariables(equationParts.get(1), vars)) {
equation = equationParts.get(1);
ConsCell temp = parser.run(parser.preProcess(equationParts.get(0)));
if (temp.getCarType() != ConsType.NUMBER || temp.length() != 1)
throw new UndefinedResultException("The NumericalSolver requires that the equation contain only one variable.", null);
answer = (BigDec) temp.getCar();
}
}
this.equation = parser.preProcess(equation).clone();
variableCells = new ArrayList<ConsCell>();