I'm trying to understand the general idea of Stone Representation Theorem (or, at least, the existence of a functor from the category of boolean algebras to the category of compact totally disconnected spaces) with the example $B=\{0,1,2,3\}$.
The corresponding Stone space contains all ultrafilters on $B$ (which are all subsets of $B$ that contains $1$ and exactly $a$ or $¬a$, $a \in B$), so $S(B)=\{ \{1,2\},\{1,3\} \}$. Also, the basis of the space is $\beta_{S(B)}= \{ U \in S(B) \mid b \in U\} = \{ \emptyset,\{1,2\},\{1,3\} \}$. But that makes no sense, since the union of all elements of $\beta_{S(B)}$ is not an element of $S(B)$.
What am I missing, or misunderstanding?
In that case $S(B)$ is simply the discrete two-point space. The points are $\{1,2\}$ and $\{1,3\}$, and the open sets are $\varnothing,\big\{\{1,2\}\big\},\big\{\{1,3\}\big\}$, and $S(B)$ itself. The base is
$$\beta_{S(B)}=\big\{\{U\color{red}{\subseteq}S(B):b\in U\}:b\in B\big\}\;.$$
Here
$$\begin{align*} \{U\subseteq S(B):0\in U\}&=\varnothing\\ \{U\subseteq S(B):1\in U\}&=S(B)\\ \{U\subseteq S(B):2\in U\}&=\big\{\{1,2\}\big\}\;,\text{ and}\\ \{U\subseteq S(B):3\in U\}&=\big\{\{1,3\}\big\}\;. \end{align*}$$