Q:

Find the signature of $Q(x_1,\ldots,x_n)= \sum_{i,j=1}^{n} a_ia_jx_ix_j$

In $\mathbb{R}^n$ let $Q(x_1,\ldots,x_n)= \sum_{i,j=1}^{n} a_ia_jx_ix_j$ quadratic form.
$a:=(a_1,\ldots,a_n)\neq0$ $\in \mathbb{R}^n$ find the signature of $Q$

A:

the representing matrix of the bi-linear form f of Q is : \begin{pmatrix} \ a_1^2 &a_1a_2 & \cdots & a_1a_n \\ a_2a_1 & \ a_2^2 & \cdots & a_2a_n \\ \vdots & \vdots & \ddots & \vdots \\ a_na_1 & a_2a_2 & \cdots & \ a_n^2 \end{pmatrix}
if $a_i !=0$ we will divide the row and after that we will divide the column and we will ger matrix with rank 1 because we will get rows with 0's only or row with 1 only.

