Set of all partial functions exists

Solution 1:

Tao proves that if $A$ is a set, then $\{X\mid X\subseteq A\}$ is also a set.

For every fixed $Y\subseteq B$, consider the function $F(X)=Y^X$, and by Replacement, the set $\{Y^X\mid X\subseteq A\}$ exists. For each $Y\subseteq B$.

Next, define the function $G(Y)=\{Y^X\mid X\subseteq A\}$, and again by Replacement the set $\{G(Y)\mid Y\subseteq B\}$ exists.

Finally, apply the Union axiom (two times).

Solution 2:

I'm assuming you have already read the other answer to this question, and are currently stuck on why it suffices to show the existence of the set $$\{Y^S: S \in \mathcal{P}(X)\}.$$

If we wanted to be picky and state that two partial functions are not considered to be equal if their codomains are unequal (as Tao does), we could instead revise the proof given in the link above to work for every fixed subset $Y' \subset Y$. In particular, we show the existence of the set $$\{{Y'}^S: S \in \mathcal{P}(X)\}$$ for each $Y' \subset Y$. Then it follows from the axiom of replacement on $\mathcal{P}(Y)$ that $$\{\{T^S: S \in \mathcal{P}(X)\}: T \in \mathcal{P}(Y)\}$$ is a set (by taking $P(x, y) = \text{$x \in \mathcal{P}(Y)$ and $y = \{x^S: S \in \mathcal{P}(X)\}$}$). Note that the set above is a set of sets; in particular, if we apply the axiom of union $$\bigcup \{\{T^S: S \in \mathcal{P}(X)\}: T \in \mathcal{P}(Y)\},$$ we see that the resulting set is what we wanted; the set of all partial functions from $X$ to $Y$.