If $f$ is a continuous function from $R^3$ to $R$ and $K⊂R^3$ is compact, show that there exist two points $a, b ∈ K$ so that $f(K)⊂[f(a),f(b)]$. When is $f(K)=[f(a),f(b)]$?
What I believe is the right direction:
Let $\{V_i\}$ be an open cover of $f(K)$; since $f$ is continuous $f^{-1}(K)$ is an open cover of K.
Let $\{f^{-1}(V_1),\dots,f^{-1}(V_k)\}$ be a finite cover of $K$, because $K$ is compact.
$K⊂f^{-1}(V1)∪\dots\cup f^{-1}(V_k)$
then
$f(K)⊂V_1∪\dots ∪V_k$
Now I don't know how to put this formally from here, albeit a incomplete idea
$f(a)⊂V_1$, $f(b)⊂V_k$ and since the continous map of a compact function is compact, then it must be a closed interval in $R$?...
Here's another question: Show that the continuous real function maps the set $[a,b]\times[c,d]$ in a real interval $[m,M]$.
What you have proved is essentially that $f(K)$ is compact. Then, as any compact in the real line, it is closed and bounded. In particular, it has a maximum $M$ and a minimum $m$, so $f(K)\subset[m,M]$.
However, $m\in f(K)$, so there's $a\in K$ with $m=f(a)$; similarly, there is $b\in K$ such that $f(b)=M$.
Therefore $f(K)\subset[f(a),f(b)]$.
As far as the other question is concerned, the answer is: when $f(K)$ is connected. A sufficient condition is that $K$ is connected, which is the case for $[a,b]\times[c,d]$.