@Override
	protected ColumnNode selectColumn() {
		ColumnNode resultNode = null;
		int minSize = Integer.MAX_VALUE;
		int ties = 0;
		for (ColumnNode node = head.right; node != head; node = node.right) {
			if (node.size < minSize) {
				minSize = node.size;
				resultNode = node;
				ties = 1;
			} else if (node.size == minSize) {
				++ties;
			}
		}

		if (minSize > 1 && ties > 1) {
			// break the tie using the degree heuristic
			int maxDegree = Integer.MIN_VALUE;
			for (ColumnNode node = head.right; node != head; node = node.right) {
				if (node.size == minSize) {
					final int degree = degree(node);
					if (degree > maxDegree) {
						maxDegree = degree;
						resultNode = node;
					}
				}
			}
		}
		return resultNode;
	}