Hall's Marriage Theorem/General Set

Theorem
Let $\mathcal S = \langle S_k \rangle_{k \in I}$ be an indexed family of finite sets.

For each $F \subseteq I$, let $Y_F = \bigcup_{k \in F} S_k$.

Let $Y = Y_I$.

Then the following are equivalent:


 * $(1)\quad$ $\mathcal S$ satisfies the marriage condition: for each finite subset $F$ of $I$, $|F| \le \left| Y_F \right|$.


 * $(2)\quad$ There exists an injection $f: I \to Y$ such that for each $k \in I$, $f(k) \in S_k$.

$(2)$ implies $(1)$
Suppose that for some finite $F \subseteq I$, $|F| > |Y_F|$.

Then $|F| \not\le |Y_F|$, so there can be no injection from $F$ to $Y_F$.

Thus there can be no injection from $I$ to $Y$ satisfying the requirements.

$(1)$ implies $(2)$
Then define $\Phi(x)$ as the set of all elements of $y$ in the expression of $x$.

Let $\mathcal F$ be the set of all partial functions $g$ from $I$ to $Y$ such that:


 * $g$ is one-to-one.
 * If $(k,y) \in g$, then $y \in S_k$.

Then for any $k \in I$, $\{ g(x): g \in \mathcal F \land k \in \operatorname{Dom}(g) \}$ is finite.

$\mathcal F$ has finite character:

Let $g \in \mathcal F$.

Let $F$ be a finite subset of $I$.

Then $g \restriction F$ is obviously in $\mathcal F$.

Suppose instead that $g$ is a partial function from $I$ to $Y$ and its restriction to each finite subset of $\operatorname{Dom}(g)$ is in $\mathcal F$.

Then $g$ is one-to-one: Let $p,q \in \operatorname{Dom}(g)$ with $p \ne q$.

Then $\{p, q\}$ is a finite subset of $\operatorname{Dom}(g)$, so $g \restriction \{p, q\} \in \mathcal F$.

Thus $g(p) \ne g(q)$.

If $(k,y) \in g$, then $(k,y) \in g \restriction \{k\}$, so $y \in S_k$.

Thus $g \in \mathcal F$.

So we see that $\mathcal F$ has finite character.

Let $F$ be a finite subset of $I$.

By the finite case, there is an element of $\mathcal F$ with domain $F$.

By the Cowen-Engeler Lemma, $\mathcal F$ has an element $\phi$ whose domain is $I$ (that is, it is a mapping from $I$ to $Y$).

But a one-to-one mapping is an injection, so $\phi$ is an injection from $X$ to $Y$.

By the definition of $\mathcal F$, $\phi(k) \in S_k$ for each $k \in I$.