I am following a lecture series on YouTube, and in the series the lecturer skipped the proof of the Theorem on the Dimension of Fibres. I tried to follow the style of the professor's proof but I failed miserably by proving a wrong statement.
Statement of the theorem:
$\textbf{Theorem}$ (Theorem on the Dimension of Fibres Part 1)
Let $f:X\rightarrow Y$ be a surjective morphism (regular maps) of varieties (either affine, projective or quasiprojective). Let $n:=\dim X - \dim Y$. Then $\forall p\in Y$, $\dim\,f^{-1}(p)\geq n$.
The problem is that I proved this with the last inequality becoming $\dim\,f^{-1}(p)=n$...
Here is my attempt of proving:
$\textit{Attempted Proof}$
Let $p\in Y$ be a fixed element.
If $Y$ is a projective or quasiprojective variety, we can use the open affine cover of $\mathbb{P}^n$, i.e. $A_i=\{[x_0,\dots,x_n]\in \mathbb{P}^n:x_i\neq 0\}$, to find a open affine set $\tilde Y$ containing $p$. Then let $\tilde X := f^{-1}(\tilde Y)$, we have $f:\tilde X\rightarrow \tilde Y$ be a surjective morphism, and $X$ is also affine.
Hence, we can rephrase the question with $X$ and $Y$ be affine varieties.
Proceed by induction on \$\dim Y$.
When $Y$ is a point, then trivially $f^{-1}(p)$ has dimension $n$.
Now let $\dim Y=k>0$ being an affine variety. Then, if we have $p=(p_1,p_2,\dots,p_k)\in\mathbb{A}^k$, $\bigcap_{i=1}^k Z(x_i-p_i)=\{p\}$ and thus by set theory, there exists an integer $i$ such that $ Z(x_i-p_i)\not\subseteq Y$ and thus $Y\cap Z(x_i-p_i)\neq Y$. Since $p\in Y\cap Z(x_i-p_i)$ so the intersection is non-empty. Then since $Z(x_i-p_i$ is a hyper surface, let $\hat Y := Y\cap Z(x_i-p_i)$, we have $\dim\hat Y = \dim Y - 1$.
Then let $\hat X := f^{-1}(\hat Y) = X\cap Z((x_i-p_i)\circ f)$. $\hat X\neq X$ since we have that $X\rightarrow Y$ being a surjective morphism, so since we have $\hat Y\subsetneq Y$, we have that $\hat X\subsetneq X$. Also, it is non-empty since there is image. So we have $\dim\hat X = \dim X - 1$.
By induction hypothesis, all irreducible components of $\hat X$ and $\hat Y$ satisfies the equation $\dim A - \dim B = n$ ($A\subseteq \hat X$, $B\subseteq \hat Y$ irreducible components) and hence we have finished the proof that $\dim X - \dim Y = n$ by induction.
I understand that there must be something wrong in my proof but I really cannot find out which part is wrong. Thank you for lending me a helping hand.
It is not true that $\widetilde{X}$ is also affine. Consider the case of the blowup of a point in $\Bbb P^2$, ie $Bl_p\Bbb P^2\to \Bbb P^2$: the preimage of any affine open containing $p$ is not affine, as it contains a closed subvariety which is projective (the $\Bbb P^1$ over $p$). The rest of your proof will require some significant adjustment after fixing this.