§ Exact sequence of pointed sets

This was a shower thought. I don't even if these form an abelian category. Let's assume we have pointed sets, where every set has a distinguished element *. pp will be analogous to the zero of an abelian group. We will also allow multi-functions, where a function can have multiple outputs. Now let's consider two sets, A,BA, B along with their 'smash union' ABA \vee B where we take the disjoint union of A,BA, B with a smashed *. To be very formal:
AB={0}×(A{}){1}×(B{}){} A \vee B = \{0\} \times (A - \{ * \}) \cup \{1\}\times (B - \{ * \}) \cup \{ * \}
We now consider the exact sequence:
(AB,)Δ(AB,)π(AB,) (A \cap B, *) \xrightarrow{\Delta} (A \vee B, *) \xrightarrow{\pi} (A \cup B, *)
with the maps as:
abABΔ(0,ab),(1,ab)AB(0,a)ABπ{if aBaotherwise(1,b)ABπ{if bAbotherwise \begin{aligned} &ab \in A \cap B \xmapsto{\Delta} (0, ab), (1, ab) \in A \vee B \\ &(0, a) \in A \vee B \xmapsto{\pi} \begin{cases} * & \text{if } a \in B \\ a &\text{otherwise} \\ \end{cases} \\ &(1, b) \in A \vee B \xmapsto{\pi} \begin{cases} * & \text{if } b \in A \\ b &\text{otherwise} \\ \end{cases} \\ \end{aligned}
  • We note that Δ\Delta is a multi-function, because it produces as output both(0,ab)(0, ab) and (1,ab)(1, ab).
  • ker(π)=π1()={(0,a):aB}{(1,b):bA}\ker(\pi) = \pi^{-1}(*) = \{ (0, a) : a \in B \} \cup \{ (1, b) : b \in A \}
  • Since it's tagged (0,a)(0, a), we know that aAa \in A. Similarly, we know that bBb \in B.
  • Hence, write ker(π)={(0,ab),(1,ab):abAB}=im(Δ)\ker(\pi) = \{ (0, ab), (1, ab) : ab \in A \cap B \} = im(\Delta)
This exact sequence also naturally motivates one to consider ABAB=AΔBA \cup B - A \cap B = A \Delta B, the symmetric difference. It also gives the nice counting formula AB=AB+AB|A \vee B| = |A \cap B| + |A \cup B|, also known as inclusion-exclusion. I wonder if it's possible to recover incidence algebraic derivations from this formuation?

§ Variation on the theme: direct product

This version seems wrong to me, but I can't tell what's wrong. Writing it down:
(AB,)Δ(A×B,(,))π(AB,) \begin{aligned} (A \cap B, *) \xrightarrow{\Delta} (A \times B, (*, *)) \xrightarrow{\pi} (A \cup B, *) \end{aligned}
with the maps as:
abABΔ(ab,ab)A×B(a,b)A×Bπ{if a=ba,botherwise \begin{aligned} &ab \in A \cap B \xmapsto{\Delta} (ab, ab) \in A \times B \\ &(a, b) \in A \times B \xmapsto{\pi} \begin{cases} * & \text{if } a = b \\ a, b &\text{otherwise} \\ \end{cases} \\ \end{aligned}
One can see that:
  • ABΔA×BA \cap B \xrightarrow{\Delta} A \times B is injective
  • ABπABA \cap B \xrightarrow{\pi} A \cup B is surjective
  • ker(π)=π1()={(a,b):aA,bB,a=b}=im(Δ)ker(\pi) = \pi^{-1}(*) = \{ (a, b) : a \in A, b \in B, a = b \} = im(\Delta)
Note that to get the last equivalence, we do not consider elements like π(a,)=a,\pi(a, *) = a, * to be a pre-image of *, because they don't exact ly map into * [pun intended].