I have a problem with this because I didn't use one of the hypotheses (compactness of $K$) during the demonstration. Thank you in advance for your help
Question: Let $K\subset \mathbb{R}^n$ a compact. Show that the projection $\pi: \mathbb{R}^m \times \mathbb{R}^n \to \mathbb{R}^m$, with $\pi(x,y)=x$, transforms all closed subset $F\subset \mathbb{R}^m \times K$ in a closed set $\pi(F)\subset\mathbb{R}^m.$
My attempt:
Continuity of $\pi$:
Take $(a,b)\in \mathbb{R}^m \times \mathbb{R}^n$. Since that $\delta \leq \epsilon$, then
$$||x-a||\leq ||(x,y)-(a,b)||<\delta \implies ||\pi(x,y)-\pi(a,b)||=||x-a||<\delta\leq \epsilon.$$
Transform closed in closed:
Take $a\in \pi(F)$. Then, $a=\pi(a,b)$, with $(a,b) \in F$. Since that $F$ is closed, exists a sequence $\{(a_k, b_k)\}$ in $F$ such that
$$(a,b)=\lim (a_k, b_k).$$
By the continuity of $\pi$,
$$a=\pi(a,b)=\pi(\lim (a_k, b_k))=\lim \pi(a_k,b_k)=\lim a_k.$$
Since every element in the $\pi(F)$ is limit of a sequence of points in the $\pi(F)$, it follows that the set is closed.
You haven't shown that $\pi(F)$ is closed because you carried out the opposite process of showing something is closed in a metric space: you first picked $a \in \pi(F)$ and then tried to construct a sequence converging to it. This is always possible in arbitrary sets and it does not say anything about whether a set is closed or not. What you have to do is the opposite. You are first given an $a \in \mathbb{R}^m$ and a sequence $a_n \in \pi(F)$ (for $n \in \mathbb{Z}_+$) converging to it. Then, you have to derive that $a \in \pi(F)$.
To do this, note that as each sequence element $a_n$ is in the image $\pi(F)$, you get corresponding sequence elements $x_n \in F \subseteq \mathbb{R}^m \times K$ such that $x_n = (a_n, b_n)$ for some $b_n \in K$. So, $b_n$ is a sequence in $K$. Thus, $K$ being compact, we must have a convergent subsequence $b_{n(s)}$ (where $s \mapsto n(s)$ from $\mathbb{Z_+}$ to $\mathbb{Z}_+$ is an increasing map) converging to some $b \in K$. Now, as the subsequences converge to the same limit as their parent sequences, the subsequence $a_{n(s)}$ must converge to $a$. So, as a whole, $x_{n(s)} = (a_{n(s)}, b_{n(s)})$ in $F$ must converge to $(a, b)$. As $F$ is closed, this means that $(a, b)$ must be in $F$. But then, $a = \pi(a, b)$ must belong to $\pi(F)$ as desired.