worked out the top level algorithm for Solver.solve()