private void find() {
		
		if (this.csp.getdomvariable().size() <= this.index) {
			return;
		}
	/**
	 * Automatically Selects 
	 * */
		Domain currentDomain = this.csp.getDomain(this.index, this.solution);
		int nextval = currentDomain.getFirst();
		int domaindir = this.csp.getDomainNumber(currentDomain);
		if (nextval == Integer.MIN_VALUE) 
		{
			return;
		}
/**
 * Domain Number 
 * */		
		Tuple<Integer,Integer> solutionTuple = new Tuple<Integer,Integer>(domaindir, nextval);
		this.solution.add(solutionTuple);
		if (index + 1 >= this.csp.getNumberOfdomvariable()) 
		{
			index++;
			return;
		}
		if (this.checkForward(nextval, domaindir)) {
			this.index++;
			this.find();
			if (this.csp.getdomvariable().size() <= this.index) {
				return;
			}
			this.index--;
		}
		if (index > 0) {
			this.history.get(index - 1).add(new Tuple<Integer,Integer>(domaindir, nextval));
		}
		this.solution.remove(solutionTuple);
		
		currentDomain.decreaseValue(nextval);
		
		List<Tuple<Integer,Integer>> currentHistory = this.history.get(this.index);
		for (Tuple<Integer, Integer> entry : currentHistory) {
			this.csp.getdomvariable().get(entry.getfirst()).increaseValue(entry.getSecond());
		}
		currentHistory.clear();	
		
		if (currentDomain.getval().size() < 1) {
			return;
		}
		
			this.find();
	}