uk.co.keang.sudoku.solver
Class SplitGroupsSolver

java.lang.Object
  extended by uk.co.keang.sudoku.solver.AbstractSolver
      extended by uk.co.keang.sudoku.solver.SplitGroupsSolver

public class SplitGroupsSolver
extends AbstractSolver

Provides resolution by looking for a triplet that only contain 3 common numbers (they do not each need to contain all of the common numbers but must not contain any other numbers) these numbers can be removed from all other cells in the group. This also tests for quads of 4 common numbers

Author:
A.G.Docherty

Nested Class Summary
 
Nested classes/interfaces inherited from class uk.co.keang.sudoku.solver.AbstractSolver
AbstractSolver.SolverDifficulty
 
Field Summary
 
Fields inherited from class uk.co.keang.sudoku.solver.AbstractSolver
found, hGrid, puzzle
 
Constructor Summary
SplitGroupsSolver(Puzzle grid)
           
 
Method Summary
 int findSolutions()
          Runs the solver once to try to resolve individual squares
 
Methods inherited from class uk.co.keang.sudoku.solver.AbstractSolver
addSolverListener, fireSolutionEvent, getDifficultyFactor, getSolverDifficulty, hasSolverListeners, removeAllFromSet, removeAllSolverListeners, removeSolverListener, retainAllInSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SplitGroupsSolver

public SplitGroupsSolver(Puzzle grid)
Method Detail

findSolutions

public int findSolutions()
                  throws IllegalGridException
Description copied from class: AbstractSolver
Runs the solver once to try to resolve individual squares

Specified by:
findSolutions in class AbstractSolver
Returns:
the number of solutions found
Throws:
IllegalGridException