[Math] Is the set of binary sequences with no consecutive ones countable

elementary-set-theory

A binary sequence is an infinite list of zeroes and ones, ie, $b$ is a binary sequence means that $b = b_1,b_2,b_3,…,b_i,…,$ where each $b_i \in \{0,1\}$. Let $C$ be the subset of $B$ containing only those sequences that have no consecutive ones. Decide whether or not C is countable.

My attempt:

Consider an element $c_i \in C$ and its sequence of digits in a decimal expansion, perhaps $0.1010101.$ Although there may be no consecutive ones, there may be infinitely many ones. Thus another element $c_{i+1}$ and its sequence could be $0.1010101$. The only way a certain $c_n$ couldn't belong in $C$ is if it had at least two 1's next to each other, which simply can't be the case. This makes $C$ countably infinite.

Best Answer

No, you are wrong, $C$ is uncountable. And it's not that hard to define injective function $f:B\to C$. For instance you could insert $0$ between every consecutive digits in each sequence from $B$. Now knowing that $B$ is uncountable, $C$ is also uncountable by Cantor-Bernstein-Schroeder theorem.

Edit: You are not removing anything. We got injection from $B$ into $C$, so $|B|\leq|C|$, which is already sufficient to conclude that $C$ is uncountable, as $B$ is uncountable. But also $|C|\leq|B|$, as $C\subset B$, hence $|B|=|C|$. And just to be precise $f$ can by defined by: $$ f(b)(n) = \begin{cases} b\left(\frac n2\right), & \text{if $n$ is even} \\ 0, & \text{if $n$ is odd} \\ \end{cases} $$

Related Question