# Are $\textbf{Set}$ and $\textbf{Ab}$ distributive categories?

A quick one-line comment on wikipedia says that the category $\textbf{Set}$ is distributive, but does not offer proof. I think I intuitively see this, as the product of sets is just the cartesian product, and the coproduct is the disjoint union, and I believe that the cartestian product distributes over the disjoint union. However, is there a more rigorous proof to show this? Perhaps that for the canonical morphism $(A\times B)\oplus(A\times C)\to A\times (B\oplus C)$ there is a morphism going in the reverse direction which gives the identity on both objects when composed?

It's also mentioned that $\textbf{Grp}$ is not distributive. I don't think I'm quite ready to tackle the concept of the free product, so I want to just look at $\textbf{Ab}$, the category of abelian groups. I know that here the product is just the direct product of groups, and the coproduct is the direct sum of groups. These products look similar in nature, so my hunch is that $\textbf{Ab}$ is also distributive, but I'm not sure either way.

Can someone provide a proof or reference that $\textbf{Set}$ is distributive, and whether $\textbf{Ab}$ is or not?

-

You're overthinking the case of $\text{Set}$. You probably know explicit descriptions of the product and coproduct, and it's not hard to show that the canonical morphism is an isomorphism by inspection (show by hand that it's injective, show by hand that it's surjective).
$\text{Ab}$ is not distributive. There is a counterexample using finite cyclic groups.
@groops: Let $A=\mathbb{Z}_2$, and let $B$ and $C$ be the trivial group. $(A\times B)\oplus(A\times C)$ is the Klein $4$-group, and $A\times(B\oplus C)$ is $\mathbb{Z}_2$, so they aren’t even the same size. – Brian M. Scott Sep 18 '11 at 23:15