Every injective function is an inclusion (up to a unique bijection) Let $X$ be a set and let $A$ be a subet of $X$. Let $i:A\longrightarrow X$ be the usual inclusion of $A$ in $X$. Then $i$ is an example of an injective function.

I want to show that every injective function is of this kind.

More precisely: for every set $Y$ and every injective function $f:X\longrightarrow Y$, there exist a subset $B$ of $Y$ and a bijection $g:X\longrightarrow B$ such that $f$ factors through $B$, i.e. $f=j\circ g$, where $j$ is the inclusion of $B$ in $Y$. Moreover, $g$ is unique with respect to this property.
I can take $B:=f(X)$ and $g:=f$ (so that $g$ is the same of $f$ as a rule, but with different codomain) and it is easely checked that everything works. Moreover $g$ is unique, since $j\circ g=f=j\circ g'$ implies $g=g'$ by injectivity of $j$.

There is something that does not convince at all, in the unicity part.

I mean, $g$ is unique if I fix $B=f(X)$, but what about the unicity of $B$? Is there a $B'$, different from $B$, and a $g'$ from $X$ to $B'$ bijective, such that $j'\circ g'=f$ holds?

No. If $j' \circ g' = f$ then $j'(g'(x)) = f(x)$ for all $x \in X$. But $j'$ is the inclusion of $B'$ in $Y$, so it acts by the identity on elements of $B$, which the $g'(x)$ are, by definition of $g' : X \rightarrow B'$. Hence $g'(x) = f(x)$ for all $x \in X$, so $B' = f(X)$.
