Find an example of K, A, B, and I to show $\beta_i\neq \beta_i(A)+\beta_i(B)-\beta_i(A\cap B)$

I’ve been trying to find a simplicial complex $$K$$, where $$A$$ and $$B$$ are subcomplexes, and $$K=A\cup B$$ to show that the Betti number

$$\beta_i(K)\neq \beta_i(A)+\beta_i(B)-\beta_i(A\cap B)$$

but every complex I come up with contradicts this for $$i=0$$, what would be a good example for this?

• What is "= / ="? Do you mean "not equal"? Use "\neq" in MathJax to get "$\neq$" – MPW Nov 30 '18 at 16:56
• I already fixed it, thanks – LexyFidds Nov 30 '18 at 16:57
• Look at the Mayer--Vietoris sequence, this will give you the precise relation between these numbers. – Pedro Tamaroff Nov 30 '18 at 17:18

Here's an example (for $$i=0$$) where $$\beta_0(K)\neq\beta_0(A)+\beta_0(B)-\beta_0(A\cap B)$$. Let simplicial complex $$K$$ be the boundary of a triangle, with three vertices $$$$, $$$$, $$$$, and three edges $$[0,1]$$, $$[1,2]$$, $$[2,0]$$. Let subcomplex $$A$$ be the union of two edges, containing all three vertices $$$$, $$$$, $$$$, and only two edges $$[0,1]$$, $$[1,2]$$. Let subcomplex $$B$$ be the third remaining edge, containing vertices $$$$, $$$$ and only one edge $$[2,0]$$. We have $$K=A\cup B$$.
Note that $$K$$, $$A$$, and $$B$$ are each connected, giving $$\beta_0(K)=\beta_0(A)=\beta_0(B)=1$$. However, $$A\cap B$$ consists of two connected components (two vertices $$$$ and $$$$), giving $$\beta_0(A\cap B)=2$$. So we have $$\beta_0(K)=1\neq 0=1+1-2=\beta_0(A)+\beta_0(B)-\beta_0(A\cap B),$$ as desired. Note in this example that $$\beta_1(K)=1$$ is nonzero, agreeing with the Mayer-Vietoris long exact sequence (https://en.wikipedia.org/wiki/Mayer%E2%80%93Vietoris_sequence).