Looking for clarification on this definition: $K_1K_2 = K_1(K_2)$. In my algebra book they define for field extensions
$L/K_1/F$ and $L/K_2/F$ the field $K_1K_2 = K_1(K_2)$.
The formal definition I have for this is
$$ K_1(K_2) = \bigcap_{K_2 < E < L} E \quad \text{where } E/K_1. $$
So the smallest field extension of $K_1$ containing $K_2$.
For extensions such as $F(\alpha)$ though sometimes it is written,
$$ F(\alpha) = \{ a_0 + a_1\alpha + a_2\alpha^2 + \cdots + a_{n - 1}\alpha^{n - 1} : a_i \in F\} $$
Can I extend this definition for $K_1(K_2)$ and write the following?
$$ K_1(K_2) = \left\{ \sum_{i = 1}^n \sum_{j = 1}^{m_i} a_{ij}b_i^j : a_{ij} \in K_1, b_i \in K_2, n, m_i \in \mathbb{N} \right\}$$
EDIT: $K_1, K_2$ are algebraic.
 A: There are several different-looking definitions of the compositum $K_1K_2$ of two fields, and it’s a very useful exercise to sit down and prove them equivalent. Here's my suggestion: Let's consider only subfields and subsets of some larger field $\Omega$. Then for a field $K$ and a set $S$, take as definition of $K(S)$ something close to what you wrote, namely
$$
K(S)=\bigcap_{L\supset K\cup S}L\,,
$$
where the index $L$ runs through fields only. The construct is a field, of course.
Now on the other hand, consider the set $K^{\mathrm{r}}(S)$ whose elements are the finite rational expressions (with coefficients in $K$) of the form $f({\mathbf{s}})=n({\mathbf{s}})/d({\mathbf{s}})$, where in each case, $\mathbf{s}$ represents some finite set of elements of $S$, and the numerator $n$ and the denominator $d$ are multivariable polynomials over $K$. Clearly $K^{\mathrm{r}}(S)$ is also a field. Now you can easily check that $K(S)=K^{\mathrm{r}}(S)$. It follows immediately that for two fields, $K_1(K_2)=K_2(K_1)$, and you also see that in your case, where the $K_i$ are algebraic over some smaller field, you can dispense with rational expressions, and use just polynomial ones.
