Proof of Cauchy-Schwarz inequality from Terry Tao's notes, meaning of "cancelling the phase" I was reading Tao's proof of the Cauchy-Schwarz inequality by exploiting certain inherent symmetries and making some transformations.
He says that first we use the fact that the norm is positive, i.e.
$$\|u-v\|^2>0$$ to conclude that $\operatorname{Re} (\langle u,v\rangle) \leq \frac{1}{2}\|u\|^2+\frac{1}{2}\|v\|^2$,
 and then he claims that we make a transformation $$v \mapsto ve^{\iota \theta}$$
and the RHS is clearly preserved under the transformation whereas the LHS changes. Now he says that we choose a $\theta$ to make the LHS as high as possible such that it cancels the phase of $\langle u,v\rangle$.
The rest of the proof is clear. But I don't get what he means by cancelling the phase. I mean the transformation is such that $\operatorname{Re} (\langle u,v\rangle)e^{\iota \theta} \mapsto |\langle u,v\rangle|$ for the theta which cancels the phase and for this particular theta we are kind of recovering the imaginary part of the complex scalar and then take its length. But how does it work? I don't understand it.  

Cancelling the phase means to choose $\theta$ so that $e^{i\theta}\langle u,v\rangle$ is real. A priori all we know about $\langle u,v\rangle$ is that it is some complex number $\langle u,v\rangle = re^{i\varphi}$, so choosing $\theta = -\varphi$ (i.e. "cancelling the phase" on this complex number) will make $e^{i\theta}\langle u,v\rangle$ a (nonnegative) real number. This optimizes the inequality because $|\text{Re}(e^{i\theta}\langle u,v\rangle)| \leq |\langle u,v\rangle|$, and equality holds precisely when $e^{i\theta}\langle u,v\rangle$ is real.
