# Lagrange’s identity

Let $R$ be a commutative ring, and let $x_{1},\ldots,x_{n},y_{1},\ldots,y_{n}$ be arbitrary elements in $R$. Then

 $\left(\sum_{k=1}^{n}x_{k}y_{k}\right)^{2}=\left(\sum_{k=1}^{n}x_{k}^{2}\right)% \left(\sum_{k=1}^{n}y_{k}^{2}\right)-\sum_{1\leq k
###### Proof.

Since $R$ is commutative   , we can apply the binomial formula.We start out with

 $\left(\sum_{i=1}^{n}x_{i}y_{i}\right)^{2}=\sum_{i=1}^{n}(x_{i}^{2}y_{i}^{2})+% \sum_{1\leq i (1)

Using the binomial formula, we see that

 $(x_{i}y_{j}-x_{j}y_{i})^{2}=x_{i}^{2}y_{j}^{2}-2x_{i}x_{j}y_{i}y_{j}+x_{j}^{2}% y_{i}^{2}.$

So we get

 $\displaystyle\left(\sum\limits_{i=1}^{n}x_{i}y_{i}\right)^{2}+\sum\limits_{1% \leq i $\displaystyle=$ $\displaystyle\sum\limits_{i=1}^{n}\left(x_{i}^{2}y_{i}^{2}\right)+\sum\limits_% {1\leq i (2) $\displaystyle=$ $\displaystyle\left(\sum\limits_{i=1}^{n}x_{i}^{2}\right)\left(\sum\limits_{i=1% }^{n}y_{i}^{2}\right)$ (3)

Note that changing the roles of $i$ and $j$ in $x_{i}y_{j}-x_{j}y_{i}$, we get

 $x_{j}y_{i}-x_{i}y_{j}=-(x_{i}y_{j}-x_{j}y_{i}),$

but the negative sign will disappear when we square. So we can rewrite the last equation to

 $\left(\sum\limits_{i=1}^{n}x_{i}y_{i}\right)^{2}+\sum\limits_{1\leq i (4)
Title Lagrange’s identity LagrangesIdentity 2013-03-22 13:18:01 2013-03-22 13:18:01 mathcam (2727) mathcam (2727) 21 mathcam (2727) Theorem msc 13A99