Type is Realized in some Elementary Extension

Theorem
Let $\mathcal M$ be an $\mathcal L$-structure.

Let $A$ be a subset of the universe of $\mathcal M$.

Let $p$ be an $n$-type over $A$.

There exists an elementary extension of $\mathcal M$ which realizes $p$.

Proof
The idea is to work in a language with constant symbols for all elements of $\mathcal M$ and show that the union of $p$ and the elementary diagram of $\mathcal M$ is satisfiable.

Since $\mathcal M$ naturally embeds into any model of such a theory, this will prove the theorem.

Let $\mathcal L_\mathcal M$ be the language obtained by adding to $\mathcal L$ constant symbols for each element of $\mathcal M$.

Denote by $\operatorname {Diag}_{\mathrm {el}} \left({\mathcal M}\right)$ the elementary diagram of $\mathcal M$.

Let $T$ be $p \cup \operatorname {Diag}_{\mathrm{el}} \left({\mathcal M}\right)$.

We will show that $T$ is finitely satisfiable. It will follow by the Compactness Theorem that $T$ is satisfiable.

To this end, let $\Delta$ be a finite subset of $T$.

We have that $\Delta$ is finite.

Thus it consists of:
 * finitely many $\mathcal L_A$-sentences $\phi_0, \dotsc, \phi_n$ from $p$ (which are $\mathcal L_\mathcal M$ sentences since $A \subseteq \mathcal M$)

along with:
 * finitely many $\mathcal L_\mathcal M$-sentences $\psi_0,\dots,\psi_k$ from $\operatorname{Diag}_{\mathrm{el}} \left({\mathcal M}\right)$.

By definition, $p$ is satisfiable by some $\mathcal L_A$-structure $\mathcal N$ such that:
 * $\mathcal N \models p \cup \operatorname{Th}_A \left({\mathcal M}\right)$

Thus, since $\phi_0, \dotsc, \phi_n \in p$:
 * $\mathcal N$ satisfies $\phi_0, \dotsc, \phi_n$.

We will show that the same $\mathcal N$ also satisfies $\psi_0, \dotsc, \psi_k$.

The obstacle to overcome is that the $\psi_i$ are $\mathcal L_\mathcal M$-formulas, and we only know $\mathcal N$ as an $\mathcal L_A$-structure which satisfies sentences with parameters from $A$.

The $\psi_i$ may have parameters from $\mathcal M$ outside of $A$.

The idea is to quantify away the excess parameters and appropriately select the interpretation of new symbols so that $\mathcal N$ is a good $\mathcal L_\mathcal M$-structure.

Explicitly:

Let $\psi$ be the conjunction $\psi_0 \wedge \cdots \wedge \psi_k$.

Note that since $\psi$ is an $\mathcal L_\mathcal M$-sentence, it can be written as an $\mathcal L_A$-formula $\psi \left({\bar b}\right)$, where $\bar b$ is a tuple of parameters from $\mathcal M$ not in $A$.

By existentially quantifying away the tuple $\bar b$, we obtain an $\mathcal L_A$-sentence $\exists \bar x \psi \left({\bar x}\right)$.

Now, since $\mathcal M \models \psi \left({\bar b}\right)$, we have:
 * $\mathcal M \models \exists \bar x: \psi \left({\bar x}\right)$

Hence $\exists \bar x: \psi \left({\bar x}\right)$ is in $\operatorname{Th}_\mathcal A \left({\mathcal M}\right)$.

By choice of $\mathcal N$, it follows that:
 * $\mathcal N \models \exists \bar x: \psi \left({\bar x}\right)$

and thus there must be some tuple $\bar c$ of elements from $\mathcal N$ such that:
 * $\mathcal N \models \psi \left({\bar c}\right)$

Now, by interpreting the $\mathcal L_\mathcal M$-symbols $\bar b$ as the elements $\bar c$, we can view $\mathcal N$ as an $\mathcal L_\mathcal M$-structure which satisfies:
 * $\phi_0 \wedge \cdots \wedge \phi_n \wedge \psi_0 \wedge \cdots \wedge \psi_k$.

Thus $\mathcal N$ satisfies all of $\Delta$.

This demonstrates that $T$ is finitely satisfiable and hence satisfiable by the Compactness Theorem.

This means that there is an $\mathcal L_\mathcal M$-structure $\mathcal M^*$ which satisfies:
 * $p \cup \operatorname{Diag}_{\mathrm {el} } \left({\mathcal M}\right)$

Since $\mathcal M^*$ interprets a symbol for each element of $\mathcal M$, there is an obvious embedding of $\mathcal M$ into $\mathcal M^*$.

This embedding is elementary since $\mathcal M^*$ satisfies the elementary diagram of $\mathcal M$.

Thus $\mathcal M^*$ is an elementary extension of $\mathcal M$.

Finally, since $\mathcal M^*$ satisfies $p$, there must be a tuple of elements $\bar{d}$ such that $\mathcal M^* \models \phi \left({d}\right)$ for each $\phi \left({\bar v}\right) \in p$.

Thus $\mathcal M^*$ realizes $p$.