orthogonalization and orthonormalization I have to construct a diagonalizable and orthogonal matrix starting from this quadratic form $Q(x_1,x_2,x_3)=-2x_1x_3+2x_1x_3-2x_2x_3$ in order to reduce it in canonic form with a variables change.

I've constructed the associated symmetric matrix $\begin{bmatrix}0 &amp; -1 &amp; -1\\ -1 &amp; 0 &amp; -1\\  1&amp;  -1&amp; 0\end{bmatrix}$ with autovalues $\lambda_1=-1$ and $\lambda_2=2$, respectively by algebraic multiplicity $m(-1)=2$ and $m(2)=1$. 
Then, I've found their respective autovectors: for $\lambda_1=-1$ we have $\bar{a}=l\begin{bmatrix}1\\ 1\\ 0\end{bmatrix}+k\begin{bmatrix}-1\\ 0\\ 1\end{bmatrix}$, and for $\lambda_2=2$ we have $\bar{b}=t\begin{bmatrix}1\\ -1\\ 1\end{bmatrix}$. 

Now, to construct the orthonormal matrix i have to prove that autovectors are orthogonal two by two. If i'd had three autovectors like $l\begin{bmatrix}a\\ b\\ c\end{bmatrix}$, $k\begin{bmatrix}d\\ e\\ f\end{bmatrix}$ and $t\begin{bmatrix}g\\ h\\ i\end{bmatrix}$ I would have just prove (for example) that $l\cdot k\begin{bmatrix}a\\ b\\ c\end{bmatrix}\begin{bmatrix}d\\ e\\ f\end{bmatrix}=0$, but now my first autovector is a sum $l+k$. So i ask you:

1) How can i orthogonalize my two autovectors $\bar{a}$ and $\bar{b}$? Could you show me the algebraic passages?

After this, i know that to orthonormalize a vector i can write $\sqrt{a^2l^2+b^2l^2+c^2l^2}=1$, but now (for the second time) my autovector is a sum $l+k$. So i ask you:

2) How can i orthonormalize my first autovector $\bar{a}$?

Thanks for any help!
Thanks for your answers. So, trying to apply Gram-Schmidt to the vectors $\begin{bmatrix}1\\ 
1\\ 0\end{bmatrix}$ and $\begin{bmatrix}-1\\ 0\\ 1\end{bmatrix}$i write that $v_1=\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}$, $v_2=\begin{pmatrix}-1\\ 0\\ 1\end{pmatrix}$. Now:

$w_1=v_1=\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}$

$w_2=v_2-\frac{v_2\cdot w_1}{w_1\cdot w_1}\cdot w_1=\begin{pmatrix}-1\\ 0\\ 1\end{pmatrix}-\frac{\begin{pmatrix}-1\\ 0\\ 1\end{pmatrix}\cdot \begin{pmatrix}1\\ 1\\ 0\end{pmatrix}}{\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}\cdot \begin{pmatrix}1\\ 1\\ 0\end{pmatrix}}\cdot \begin{pmatrix}1\\ 1\\ 0\end{pmatrix}=\begin{pmatrix}-1\\ 0\\ 1\end{pmatrix}+\frac{1}{2}\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}=\begin{pmatrix}-\frac{1}{2}\\ \frac{1}{2}\\ 1\end{pmatrix}$.

Then, i normalize the vector $\begin{pmatrix}1\\ -1\\ 1\end{pmatrix}$:

$\sqrt{t^2+t^2+t^2}=\sqrt{3t^2}=1\rightarrow t_1=\frac{\sqrt{3}}{3}\Rightarrow ||\bar{b}||=t_1\begin{bmatrix}
1\\ -1\\ 1\end{bmatrix}=\begin{bmatrix}\frac{\sqrt{3}}{3}\\\frac{-\sqrt{3}}{3} \\ \frac{\sqrt{3}}{3}\end{bmatrix}$.

So, my orthonormal matrix is $P=\begin{bmatrix}1 &amp; -\frac{1}{2} &amp; \frac{\sqrt{3}}{3}\\  1&amp; \frac{1}{2} &amp; -\frac{\sqrt{3}}{3}\\  0&amp; 1 &amp; \frac{\sqrt{3}}{3} \end{bmatrix}$. 

But now, since $P=P^{T}=P^{-1}=\begin{bmatrix}1 &amp; 1 &amp; 0\\  -\frac{1}{2}&amp; \frac{1}{2} &amp; 1\\  \frac{\sqrt{3}}{3}&amp; -\frac{\sqrt{3}}{3} &amp; \frac{\sqrt{3}}{3}\end{bmatrix}$ and being the diagonal matrix $D=\begin{bmatrix}-1 &amp; 0 &amp; 0\\  0&amp; -1 &amp; 0\\  0&amp; 0 &amp; 2 \end{bmatrix}$, i obtain (for the condition $\bar{X^{T}}A\bar{X}=\bar{X^{T}}PDP^{T}\bar{X}=\bar{Y^{T}}D\bar{Y}$) that the change of variables is $\bar{Y}=P^{T}\bar{X}=\begin{bmatrix}1 &amp; 1 &amp; 0\\  -\frac{1}{2}&amp; \frac{1}{2} &amp; 1\\  \frac{\sqrt{3}}{3}&amp; -\frac{\sqrt{3}}{3} &amp; \frac{\sqrt{3}}{3}\end{bmatrix}\bar{X}$.

In the light of all this I ask you all whether the procedure is correct and, with it, the result.
Thanks again for any help.
Con "dei passaggi" intendi forse che avrei dovuto calcolare anche $w_3=v_3-\frac{v_3\cdot w_1}{w_1\cdot w_1}-\frac{v_3\cdot w_2}{w_2\cdot w_2}=\begin{pmatrix}1\\ -1\\ 1\end{pmatrix}-\frac{\begin{pmatrix}1\\ -1\\ 1\end{pmatrix}\cdot \begin{pmatrix}1\\ 1\\ 0\end{pmatrix}}{\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}\cdot \begin{pmatrix}1\\ 1\\ 0\end{pmatrix}}\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}-\frac{\begin{pmatrix}1\\ -1\\ 1\end{pmatrix}\cdot \begin{pmatrix}\frac{-1}{2}\\ \frac{1}{2}\\ 1\end{pmatrix}}{\begin{pmatrix}\frac{-1}{2}\\ \frac{1}{2}\\ 1\end{pmatrix}\cdot \begin{pmatrix}\frac{-1}{2}\\ \frac{1}{2}\\ 1\end{pmatrix}}\begin{pmatrix}\frac{-1}{2}\\ \frac{1}{2}\\ 1\end{pmatrix}=\begin{pmatrix}1\\ -1\\ 1\end{pmatrix}$?

Una volta fatto questo, i vettori normalizzati si ottengono calcolando per ognuno di essi ad es. $e_1=\frac{\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}}{||\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}||}=\frac{\begin{pmatrix}1\\ 1\\ 0\end{pmatrix}}{\begin{pmatrix}l_1\\ l_1\\ 0\end{pmatrix}}$ (con $l_1=\frac{1}{\sqrt2}$) oppure posso normalizzarli separatamente (cioè a dire $\sqrt{l^2+l^2}=1$, il che vuol dire che nella matrice diagonalizzante ortogonale andrò ad inserire direttamente $\begin{pmatrix}l_1\\ l_1\\ 0\end{pmatrix}$)?

Se la risposta fosse il primo caso, come si svolge quel rapporto matriciale?