# Why $-1 \leq\frac{\langle A,B\rangle}{||A||\, ||B||}\leq1$?

It says that due to the Cauchy-Schwarz inequality written as:

$$|\langle A,B\rangle|\leq ||A||\, ||B||$$

Then

$$-1\leq\frac{\langle A,B\rangle}{||A||\, ||B||}\leq 1$$

I am a bit confused at this. I did the following to check that if:

$$A=(a_1,a_2,a_2) \quad B=(b_1, b_2, b_3)$$

Then:

$$\frac{a_1b_1+a_2b_2+a_3b_3}{\sqrt{a_1^2+a_2^2+a_3^2}\sqrt{b_1^2+b_2^2+b_3^2}}$$

But from here, I can only expand the square roots. I don't know how to proceed.

• Wouldn't it be sufficient to check the proof of the CS inequality? Apr 16, 2015 at 12:49
• If you believe "vector calc" results that $\vec{v}\cdot \vec{u}=|\vec{v}|\cdot|\vec{u}|\cos(\theta)$ then you only have to put absolute values on things and note that $|\cos(\theta)|\leq 1$. This is re-written as $\frac{\vec{v}\cdot\vec{u}}{|\vec{v}|\cdot|\vec{u}|}=\cos(\theta)$. Apr 16, 2015 at 12:58
• Wait, which are you trying to prove? The first inequality, or figuring out why Cauchy-Schwarz implies the second inequality? Apr 16, 2015 at 13:05

So if we accept the Cauchy-Schwarz inequality (a proof can be found here):

$$|\langle A, B\rangle| \leq \|A\|\|B\| \iff -\|A\|\|B\|\leq \langle A, B\rangle \leq \|A\|\|B\|$$

Therefore dividing through by $\|A\|\|B\|$, we get:

$$-1\leq \frac{\langle A, B\rangle}{\|A\|\|B\|}\leq 1$$

I hope this helps!

Note that $$|\langle A,B\rangle|\leq ||A||\, ||B|| \iff -||A||\, ||B|| \le \langle A,B\rangle\leq ||A||\, ||B||$$

You arrived at a point where the inequality is equivalent to $$(a_1b_1+a_2b_2+a_3b_3)^2 \leq (a_1^2+a_2^2+a_3^2)(b_1^2+b_2^2+b_3^2)$$ You can see that this is true by taking a look at Lagrange's identity.

Another way to see this is to look at the discriminant of the following second degree polynomial:

$$p(x)= (a_1x+b_1)^2+(a_2x+b_2)^2+(a_3x+b_3)^2$$ Since $p(x) \geq 0$ for every $x$, it follows that the discriminant is non-positive. That is exactly the desired inequality. Of course, all arguments work for $n$ terms instead of $3$.