Solver class