totally disconnected and non Borel set.

Let $X$ be a compact metric space. There is $A\subset X$ such that is non Borel and is totally disconnected set?

• How about a non Borel subset of $[0,1]$ with the rationals removed? That would be, like, totally disconnected. – copper.hat Nov 4 '16 at 5:23
• Are you asking for an example or for conditions (sufficient or necessary) on X so that such a set exists? – DanielWainfleet Nov 4 '16 at 5:33

If $X$ is uncountable there is always such a subset.

Let $X$ be an uncountable compact metric space. $X$ is second countable, so let $\mathscr{B}$ be a countable base for $X$. Let $\mathscr{B}_0=\{B\in\mathscr{B}:|B|\le\omega\}$, and let $Y=X\setminus\bigcup\mathscr{B}_0$; then $Y$ is a closed subset of $X$ with no isolated points. Henceforth I’ll work in the space $Y$: $Y$ is a Borel subset of $X$, so non-Borel subsets of $Y$ are also non-Borel in $X$.

Let $D=\{0,1\}$ with the discrete topology, and let $C=D^\omega$, the product of countably infinitely many copies of $D$; $C$ is a Cantor set. In this answer I sketched the construction of a family $\mathscr{F}=\{F_\sigma:\sigma\in C\}$ of non-empty closed subsets of $Y$ with the following property: if $K=\bigcup\mathscr{F}$, and $U$ is an open set in $C$, then $\bigcup\{F_\sigma:\sigma\in U\}$ is a relatively open subset of $K$.

Let $K_0\subseteq K$ be such that $|K_0\cap F_\sigma|=1$ for each $\sigma\in C$, and for $\sigma\in C$ let $y_\sigma$ be the unique element of $K_0\cap F_\sigma$. The map $K_0\to C:y_\sigma\mapsto\sigma$ is then a continuous bijection, and $C$ is zero-dimensional, so $K_0$ is totally disconnected. If $K_0$ is not a Borel subset of $Y$, we’re done.

Otherwise, let $\mathscr{A}$ be the family of uncountable Borel subsets of $K_0$; $|\mathscr{A}|=2^\omega$, so we can enumerate $\mathscr{A}=\{A_\xi:\xi<2^\omega\}$. For $\eta<2^\omega$ let $p_\eta$ and $q_\eta$ be distinct elements of

$$K_0\setminus\big(\{p_\xi:\xi<\eta\}\cup\{q_\xi:\xi<\eta\}\big)\;;$$

this is always possible, since $|A_\xi|=2^\omega$ for each $\xi<2^\omega$. Then $P=\{p_\xi:\xi<2^\omega\}$ is a non-Borel subset of $X$, and since $P$ is a subset of $K_0$, $P$ is totally disconnected.