Extension of residue fields and algebraic independence Let $A$ be a Noetherian integral domain, $B$ a ring extension of $A$ that is an integral domain, $P \in \operatorname{Spec} B, \, p = P \cap A$. Denote by $\kappa(p),\ \kappa(P)$ the residue fields of the two prime ideals. Then we see that there is a field extension $\kappa(p) \hookrightarrow \kappa(P)$. Let $t$ be a non-negative integer such that $t \le {\rm tr}.\deg_{\kappa(p)} \kappa(P)$.
Matsumura in his Commutative Ring Theory, proof of Theorem 15.5, says "let $c_1,\dots,c_t \in B$ such that their images modulo $P$ are algebraically independent over $A/p$." 
Question: Why would such elements exist?
(Edited)
Remark: Matsumura wants to prove that $\operatorname{ht}(P)+\operatorname{tr.deg}_{\kappa(p)} \kappa(P) \le \operatorname{ht}(p)+ \operatorname{tr.deg}_A B$ and he starts by proving that we can assume that $B$ is a finitely generated $A$-algebra. Specifically, he is showing that we can construct a subring $C$ of $B$ that is a finitely-generated $A$-algebra, and that if the theorem is true for $C$, then it is true of $B$. My question relates to his argument of "why we can assume that". Consequently, in answering my question, we can not make the assumption that $B$ is a finitely generated $A$-algebra.
 A: Take $x_1,\dots,x_t$ to be algebraically independent over $k(p)$ in $k(P)$. Then, write each $x_i$ as a fraction. Then, you get $2t$ elements of $B/P$. I claim that there are $t$ algebraically independent among the $2t$ elements. Why? What happens if there is only $m<t$. Then, there are $m$ elements $(y_1,\dots,y_m)$ of $B/P$ such that the numerators and denominators are algebraic over $k(p)[y_1,\dots,y_m]$. But, then $B/P$ is of transcendence degree $m$ over $k(p)$. So $m=t$, and done.
A: First of all your problem reduces easily to the following:

Let $A\subset B$ be an extension of integral domains, $K=Q(A)$ and $L=Q(B)$ their fields of fractions. If ${\rm tr}.\deg L/K\ge t$, then there exist $t$ elements in $B$ which are algebraically independent over $A$.

Hint. Let $x\in L$ algebraically independent over $K$. Then write $x=b/b'$ with $b,b'\in B$, $b'\neq 0$. If both $b$ and $b'$ are algebraic over $A$, then they are algebraic over $K$, so $K\subset K(b,b')$ is an algebraic extension of fields. Since $x\in K(b,b')$ we got a contradiction. 
(The general case I'll leave it to you.)
