When the equality in the Cauchy-Schwarz inequality holds? Q19 deals with Schwartz inequality. $$x_1y_1 + x_2y_2 \le \sqrt{x_1^2 + x_2^2}\cdot \sqrt{y_1^2 + y_2^2}$$
The last part asks for each of the proofs to deduce when equality holds. Specifically, in part,

only.....when there is a number $\lambda \ge 0$ such that $x_1 = \lambda y_1$ and $x_2 = \lambda y_2 $

To prove this at a very basic level, assume $\lambda = 2.5, x_1 = 2, x_2 = 3, y_1 = 0.8$ and  $y_2 = 1.2$ Then $$2 \times 0.8 + 3 \times 1.2 = \sqrt{2^2 + 3^2}\sqrt{0.8^2 + 1.2^2} $$
$$5.2 = 5.2$$
Earlier in this chapter, Spivak made the observation that

$|a| = \sqrt{a^2}$

but clearly, for example, $\sqrt{2^2 + 3^2} \neq \sqrt{2^2} +\sqrt{ 3^2} = |2|+|3|$
My question is how to reconcile these two notions, if they are related at all. In other words, looking at the right side of the Schwartz inequality, is it wrong to assume one could apply absolute values in place of the given expression.
 A: Let $V$ be a finite dimensional vector space over the field $\textbf{K}$ endowed with an inner product $\langle\cdot,\cdot\rangle$.
In order to prove the Cauchy-Schwarz inequality, consider two vectors $v$ and $w$. Suppose $w\neq 0$, otherwise the inequality holds trivially. Then, according to Pythagoras theorem, one has that
\begin{align*}
\|v\|^{2} = \|v - \text{proj}_{w}{v}\|^{2} + \|\text{proj}_{w}v\|^{2} \geq \|\text{proj}_{w}v\|^{2} = \left\|\frac{\langle v,w\rangle}{\|w\|^{2}}w\right\|^{2} = \frac{|\langle v,w\rangle|^{2}}{\|w\|^{2}}
\end{align*}
and we are done.
Notice the equality holds iff $\|v - \text{proj}_{w}v\| = 0$, that is to say, $v$ and $w$ are linearly dependent.
Hopefully this helps!
A: Cauchy-Schwarz inequality states that
$$
| <u, v> | \leq \Vert u \Vert \Vert v \Vert \tag{1}
$$
where $u, v \in V$ are arbitrary.
Obviously, (1) holds as an equality if $v = 0$.
So, we suppose that $v \neq 0$.
We consider the orthogonal decomposition
$$
u =  {<u, v> \over \Vert v \Vert^2} \, v \ + \ w, \tag{2}
$$
where $w$ is orthogonal to $v$.
In fact,
$$
w = u - {<u, v> \over \Vert v \Vert^2} \, v  \tag{3}
$$
By the Pythagorean theorem, it follows from (2) that
$$
\Vert u \Vert^2 = \left\Vert  {<u, v> \over \Vert v \Vert^2} \, v \right\Vert^2 + \Vert w \Vert^2
$$
Simplifying, we get
$$
\Vert u \Vert^2 =  {|<u, v>|^2 \over \Vert v \Vert^2} + \Vert w \Vert^2 \geq  {|<u, v>|^2 \over \Vert v \Vert^2} \tag{4}
$$
Multiplying both sides of (4) by $\Vert v \Vert^2$, and rearranging terms, we get
$$
|<u, v>|^2 \leq \Vert u \Vert^2 \, \Vert v \Vert^2
$$
i.e.
$$
|<u, v> | \leq \Vert u \Vert \, \Vert v \Vert v \tag{5}
$$
This proves the Cauchy-Schwarz inequality.
Obviously, equality holds in (5) if and only if equality holds in (4).
Thus, equality holds in (5) if and only if $w = 0$.
From (3), we see that
$$
w = u - {<u, v> \over \Vert v \Vert^2} \, v = 0 \iff 
u = \alpha \, v
$$
where
$$
\alpha = {<u, v> \over \Vert v \Vert^2}
$$
Hence, we conclude that the equality holds in the Cauchy-Schwarz inequality if and only if $u$ and $v$ are linearly dependent.
$ \ \ \ \blacksquare$
A: Consider the quadratic polynomial
$$p(x) = \sum_{k=1}^n (a_kx-b_k)^2$$
This quadratic, being the sum of squares, is positive-valued unless each $(a_kx-b_k)$ equals zero, in which case it takes on the value of zero.
The Cauchy-Schwarz inequality and its equality condition follows from the fact that the discriminant must be nonpositive, equaling zero iff the polynomial has a real root.
