public void solve()
	{
		solveStart = System.currentTimeMillis();

		// The current state of the solver.
		SolverState state = new SolverState();
		
		// Clear solutions
		solutions = new ArrayList<State<M>>();
		
		// Clear initial state
		initial.setParent( null );
		initial.setDepth( 0 );

		// Add the initial state in, and mark it as visited.
		state.states.add( initial );
		if (!revisitStates)
		{
			state.visited.add( initial.getHash() );
		}
		
		// Create & Run the Threads
		for (int i = 0; i < workers; i++)
		{
			new Thread( new SolverThread( state ) ).run();
		}
		
		// Wait until they're finished
		try
		{
			state.finishLatch.await();
		}
		catch (InterruptedException e)
		{
			throw new RuntimeException( e );
		}
		
		// Update the statistics
		statesCreated = state.statesCreated.get();
		statesVisited = state.statesVisited.get();
		statesDuplicated = state.statesDuplicated.get();
		statesDeviated = state.statesDeviated.get();
		statesShort = state.statesShort.get();

		solveEnd = System.currentTimeMillis();
	}