private double normaliseScore(Board b)
	{
		int count = 0;
		//sum all the squares
		for (int i = 0; i < 4; i++){
			for (int j = 0; j < 4; j++){
				//if (b.boardState[i][j] >= 3 )
					count += b.boardState[i][j];
			}
		}
		//store the max possible score in maxscore
		//tileS goes from the highest single cell size down
		int maxscore = 0;
		int tileS = 786432;
		while (tileS > count)
		{
				tileS /= 2;
		}					
		while (count > 3)
		{
			
			maxscore += Board.scoreOfTile(tileS);
			count -= tileS;
			tileS /= 2;
		}
		maxscore += Board.scoreOfTile(count);
		
		//System.err.println((double) maxscore);
		return (double)b.scoreOfBoard() / (double) maxscore;
	}