Definition of a coproduct and its universal property - connection?

I have a problem connecting the definition of a coproduct with its often mentionend universal property. Let's start with the definition (just for two objects):

Let $A_1$ and $A_2$ be objects of a category $\mathcal{C}$. A coproduct of $A_1$ and $A_2$ in $\mathcal{C}$ is a triple $(A,p_1,p_2)$ where $A \in ob(\mathcal{C})$ and $p_i \in hom_\mathcal{C}(A_i,A)$ such that if $B$ is any object in $\mathcal{C}$ and $f_i \in hom_\mathcal{C}(A_i, B), i=1,2$, then there exists a unique $f \in hom_\mathcal{C}(A,B)$ such that the diagrams are commutative ($f_i = p_if$).

My apologies, I can't draw the diagram but it's pretty simple with the equation and I assume well known. While this already sounds like a universal property to me, referred to as the universal property of the coproduct is something else:

$$hom(A_1 \amalg A_2, B) \cong hom(A_1,B) \prod hom(A_2,B)$$

Now I wonder how to connect these two, e.g. how to derive this statement from the definition. It comes out of the blue for me, and I didn't came across an explanation nor a proof so far. Also often I see $\mathrm{Hom}$ instead of $hom$ - that is the same, isn't it?

• In your displayed formula, when you wrote $hom(A\times B, C)$, did you mean for the $\times$ sign to be a coproduct sign $\amalg$ (\amalg) or $\oplus$ (\oplus)? – MJD Oct 25 '14 at 16:25
• Thanks, since I'm not familiar with this second part, I can't say for sure, but I think it should be the coproduct sign. My mistake. Often it's also written in the middle, but that should be the same. – cbb Oct 25 '14 at 16:27
• Can you tell us where you saw this universal property mentioned? Someone here might have the same book and be able to explain in detail what was meant. – MJD Oct 25 '14 at 16:28
• I think you also mean to say $\operatorname{hom}(A,C)\times \operatorname{hom}(B,C)$. Whatever the case, think about how, when these hom-classes are hom-sets, the universal property tells you how to take two morphisms $f:A\rightarrow C$ and $g:B\rightarrow C$ and construct the map $f\amalg g:A\amalg B \rightarrow C$. – Hayden Oct 25 '14 at 16:28
• Sorry for beeing so incorrect, you are absolutely right. Book is a good question - my problem is that none of my sources include both, but at the Wikipedia entry it's mentionend (generalized for n objects): link The statement will be important to show that the tensor product shares the same universal property in a special case: link – cbb Oct 25 '14 at 16:33

Let $x$ and $y$ be objects of a category $C$. Their coproduct is an object $x \sqcup y$ together with morphisms $x \to x \sqcup y$ and $y \to x \sqcup y$, satisfying the universal property that given any object $z$ with maps $x \to z$ and $y \to z$, there exists a unique morphism $x \sqcup y \to z$ through which the given maps factor. Another way to say this is that the data of

• an element of the set $\mathrm{Hom}(x \sqcup y, z)$

is the same as the data of

• an element of the set $\mathrm{Hom}(x, z)$,
• and an element of the set $\mathrm{Hom}(y, z)$.

Of course, this is the same as the data of

• an element of the product of the sets $\mathrm{Hom}(x, z) \times \mathrm{Hom}(y, z)$.
• Thank you, that helped a lot! It is now clear, that for any element in $\mathrm{Hom}(x, z) \times \mathrm{Hom}(y, z)$ one can find an element in $\mathrm{Hom}(x \sqcup y, z)$ through the existence of a unique morphism. But why is the other way round true? Couldn't theoretically two different elements in $\mathrm{Hom}(x, z) \times \mathrm{Hom}(y, z)$ have the same morphism in $\mathrm{Hom}(x \sqcup y, z)$? Or even more, maybe there exists a $g \in \mathrm{Hom}(x \sqcup y, z)$ for which no fitting morphisms from $x$ and $y$ to $z$ exists? – cbb Oct 26 '14 at 10:23
• Given a morphism $x \sqcup y \to z$, one gets morphisms $x \to x \sqcup y \to z$ and $y \to x \sqcup y \to z$ by precomposition. Note that morphisms $x \to x \sqcup y$ and $y \to x \sqcup y$ are part of the definition of the coproduct. Does this answer your question? – user314 Oct 26 '14 at 11:15
• Yes indeed, thank you! – cbb Oct 26 '14 at 11:22