Let's say $A\in M_2(\Bbb{R})$ is a symmetric matrix with the eigen values $2$ and $6$. And I also know that $v_1(1,-1)$ is the corresponding eigen vector to the eigen value of $2$. How can I find $A$ in this situation?
I've taken $A$ as $ \begin{bmatrix} a & b \\ c & d \\ \end{bmatrix} $
Since it's a symmetric matrix, $A=A^t $, so I've concluded that $b=c$.
And now using this $Av_1 = \lambda_1v_1$ where $\lambda_1=2$ I've got that $a=d$
So now I would have $A$ as $ \begin{bmatrix} a & b \\ b & a \\ \end{bmatrix} $
Leading with this, I've calculated the eigen values for A and it led me to $\lambda_1=a-b$ and $\lambda_2=a+b$. I've got the values for $a$ and $b$ to be $4$ and $2$ respectively.
In the end I got $A$ as $$ \begin{bmatrix} 4 & 2 \\ 2 & 4 \\ \end{bmatrix}$$ which is symmetrical but I want to know if I got this just as a fluke and if there is a better way to find out the matrix.
If your matrix $A$ is symmetric, then it is a self-adjoint operator, and all self-adjoint operators have the following properties:
So, because you know that the subspace generated by the vector $(1,-1)$ is invariant, then the subspace generated by the vector $(1,1)$ will also be, and thus this will be an eigenvector for the eigenvalue $6$.
And I think that from here you can write the matrix $A$ in the eigenbasis $((1,1),(1,-1))$ and then just convert the matrix to the regular base of $\mathbb R^2$. Try to use the spectral theorem to make this process a little bit easier.