You're misinterpreting the meaning of the word "unique" (which was poor word choice on the part of whoever wrote that, so I am removing it). It just means that an arrow doesn't have more than one source or target.
Here is a formal definition of a small category (this will allow me to ignore size issues which I think are irrelevant when first trying to understand category theory). I'm afraid I'm too attached to words to follow the "no words" edict, but I hope this will be formal enough. A category consists of the following data:
- A set $\text{Ob}$ (objects),
- For every $a, b \in \text{Ob}$, a set $\text{Hom}(a, b)$ (morphisms from $a$ to $b$),
- For every $a \in \text{Ob}$, an element $\text{id}_a \in \text{Hom}(a, a)$ (identity),
- For every $a, b, c \in \text{Ob}$, a function $\circ : \text{Hom}(a, b) \times \text{Hom}(b, c) \to \text{Hom}(a, c)$ (composition).
(I am writing function composition in the opposite of the usual order. You should think of a morphism $f \in \text{Hom}(a, b)$ as an arrow $f : a \to b$ pointing from $a$ on the left to $b$ on the right.)
This data is subject to the following axioms:
- Identity: for every $f \in \text{Hom}(a, b)$, we have $\text{id}_a \circ f = f$, and for every $g \in \text{Hom}(b, a)$, we have $g \circ \text{id}_a = g$.
- Associativity: for every $f \in \text{Hom}(a, b), g \in \text{Hom}(b, c), h \in \text{Hom}(c, d)$, we have $f \circ (g \circ h) = (f \circ g) \circ h$.
Some concrete classes of examples to keep in mind ("categories-as-mathematical-objects" rather than "categories-as-settings-to-study-mathematical-objects") are the following:
- A monoid is a category with one object; that is, $\text{Ob}$ is a one-element set. The elements of the monoid are the morphisms from the unique object to itself.
- A poset is a category in which $\text{Hom}(a, b)$ has either $1$ or $0$ elements (corresponding to whether $a \le b$ or not); moreover, if $\text{Hom}(a, b)$ and $\text{Hom}(b, a)$ both have one element, then $a = b$. The existence of identities expresses reflexivity, the composition law expresses transitivity, and associativity is automatic.
- A groupoid is a category in which every morphism $f : a \to b$ has an inverse $g : b \to a$, which is a morphism satisfying $f \circ g = \text{id}_a, g \circ f = \text{id}_b$. Groupoids are a simultaneous generalization of groups, equivalence relations, and group actions. An important example is the fundamental groupoid $\Pi_1(X)$ of a topological space $X$, which is the groupoid whose objects are the points of $X$ and whose morphisms are the homotopy classes of paths between points in $X$; composition is given by concatenating paths.
One example of "categories-as-settings-to-study-mathematical-objects":
- The "matrix category" $\text{Mat}$ is the category whose objects are the non-negative natural numbers $\mathbb{Z}_{\ge 0}$ and whose morphisms $\text{Hom}(n, m)$ are the $n \times m$ matrices, say over some ring (or $m \times n$; whichever convention makes composition correspond to matrix multiplication).
Seems generally correct, but you could be a bit more careful.
i) An 'identity morphism' is just a distinguished element of $Hom_\mathsf{C}(A,A)$. Given a choice of $1_A$ in the category $\mathsf{C}$, it makes sense to define the identity morphism of $A$ in $\mathsf{C}^{op}$ by choosing the same $1_A$, since you know $Hom_{\mathsf{C}^{op}}(A,A) = Hom_\mathsf{C}(A,A)$.
A morphism being the identity is not an intrinsic property of some particular function, it is a structural property of a morphism in a category, so if you are building a new category you need to say what the identities are.
ii)b Take a morphism $f\in Hom_{\mathsf{C}^{op}}(A,B)$ corresponding to $f'\in Hom_{\mathsf{C}}(B,A)$. The morphism $f\circ 1_A \in Hom_{\mathsf{C}^{op}}(A,B)$ is, by your definition of composition, the morphism corresponding to $1_A\circ f'\in Hom_{\mathsf{C}}(B,A)$ which is $f'\in Hom_{\mathsf{C}}(B,A)$. Thus $f\circ 1_A = f$.
You could just use the same letters for $f$ and $f'$, of course, I just wanted to emphasize that they 'go in different directions', i.e. 'live in different categories'.
Logically speaking I would prefer you write ii) and ii)a together and put ii)b and i) together: the composition is a law for combining morphisms, calling something an identity only makes sense after defining composition. You cannot call $0$ an additive identity without knowing what addition is.
Best Answer
To be formal, you can say that a category is a triple $(Ob(C), Hom(C), \circ)$ such that, etc ...
The notion of triple is perfectly and formaly defined in set theory.
Of course, I use the definition of category which states that $Ob(C)$ and $Hom(C)$ must be sets. To work with this definition, one usually uses Grothendieck Universes.