# Showing equality in Cauchy-Schwarz inequality

With $\mathbf{u,v}$ being vectors in $\mathbb{R}^n$ euclidean space, the Cauchy–Schwarz inequality is

$${\left(\sum_{i=1}^{n} u_i v_i\right)}^2 \leq \left(\sum_{i=1}^{n} u_i^2\right)\left(\sum_{i=1}^{n} v_i^2\right)$$

further given that $\mathbf{u}=\lambda\mathbf{v}$, the csi looks like the following:

$${\left(\sum_{i=1}^{n} \lambda v_i v_i\right)}^2 \leq \left(\sum_{i=1}^{n} (\lambda v_i)^2\right)\left(\sum_{i=1}^{n} v_i^2\right)$$

With equality applying in the Cauchy-Schwarz inequality only if $\mathbf{u,v}$ are linear dependent, how do I show that equality is given in this case? A start would be enough, I'm quite new to linear algebra

Edit:
Thanks so far!
Rewriting the last line - following your advice - I get the following

$${\lambda^2\left(\sum_{i=1}^{n} v_i^2\right)}^2 \leq \lambda^2\sum_{i=1}^{n} v_i^2\sum_{i=1}^{n} v_i^2$$

Okay I'm not sure about the following, so make sure you have foul fruit nearby to throw at me:

Canceling $\lambda^2$ this results in

$${\left(\sum_{i=1}^{n} v_i^2\right)}^2 \leq \sum_{i=1}^{n} v_i^2\sum_{i=1}^{n} v_i^2$$

with the inquality being wrong, equality applies... is that evidence enough?

-
–  MSEoris May 8 '13 at 12:14
Re-write the left hand side as the product of two summations and factor out the constant from both sides and it should become a lot clearer to you that way. –  BU982T May 8 '13 at 12:15

Hints:

$$\left(\sum_{i=1}^n\lambda v_iv_i\right)^2=\lambda^2\left(\sum_{i=1}^n v_i^2\right)^2$$

$$\sum_{i=1}^n (\lambda v_i)^2\sum_{j=1}^n (v_j)^2=\lambda^2\sum_{i=1}^n v_i^2\sum_{j=1}^n v_j^2$$

-
I've updated my question with what I think might be the solution, would you mind taking a look at it? –  Rickyfox May 8 '13 at 13:12
Yes...and that's an equality. For example, for $\,n=3\,$ :$$(x^2+y^2+z^2)^2=(x^2+y^2+z^2)(x^2+y^2+z^2)$$...:) ! –  DonAntonio May 8 '13 at 14:40

Expand the following expression to get a trinom in $\lambda$:

$$\sum_{i=1}^n \left(u_i - \lambda v_i\right)^2$$

Then, write that since it's positive or zero for all values of $\lambda$, the discriminant of the trinom is negative or zero. This will give you Cauchy-Schwarz inequality. Now, equality case is found when the discriminant is zero, that is, when there is some $\lambda$ such that the first expression is zero, which gives an obvious condition between $u_i$ and $v_i$.

-