Given any two non zero vectors $x,y$ does there exist symmetric matrix $A$ such that $y = Ax$?

If $y^T x \ne 0$, you can take $A = (y^T x)^{-1} y y^T$.

If $y^T x = 0$, take $A = (x^T x)^{-1} (y x^T + x y^T)$.


It's not true that if you have more variables than equations, the system is always solvable! That's like saying a matrix with more columns than rows is always onto, which is also false.

There might be a slicker solution, but the first thing I thought of was this: Let $d = ||x||$. Then there exists a unitary matrix $U$ such that $U(x) = (d,0,0,\ldots,0)$: You can use Gram-Schmidt to create an orthonormal basis whose first vector is $x/d$, and then $U$ is the matrix whose rows are that orthonormal basis. Now, there exists a symmetric matrix A such that $A(d,0,0,\ldots,0) = U(y)$: Just set the first column of $A$ to be $U(y)/d$, and then fill in the rest of the entries to make $A$ symmetric. Now, $U^{-1}AU$ is your desired symmetric matrix sending $x$ to $y$.


Note that your system is not homogeneous (since $y \neq 0$). Given a non-homogeneous system of $k$ equations in $n \geq k$ unknowns, it is not always true that this system has a solution. For example, the system

$$ 0 \cdot x + 0 \cdot y = 1 $$

clearly doesn't have a solution. In general, a system of $k$ equations in $n$ unknowns defines a linear map $B \colon \mathbb{F}^n \rightarrow \mathbb{F}^k$. If $n > k$ then this map cannot be one-to-one so you know that the homogeneous system of equations $Bx = 0$ always has a non-trivial solution $x \neq 0$. However, you can't tell automatically that $Bx = y$ has a solution because $y$ might not belong to the image of $B$.