public int distSingle(int[] inds, int pos, int ch) {
		int size = inds.length;
		int[] inds2;
		int d = 0, i;
		if(ch >= 0) {
			inds2 = rp2c[pos][ch];
			for(i = 0; i < size; i++)
				if(i != pos && (ch=inds[i]) != inds2[i])
					d += ch >= 0 ? 2 : 1;
		} else {
			for(i = 0; i < size; i++)
				if(i != pos && (ch=inds[i]) >= 0 && rp2c[i][ch][pos] != -1)
					d++;
		}
		return d;
	}