# Finding best phase in least-squares manner

I have the following problem: $$argmin_{\vec{x},\phi}||A\vec{x}-\vec{y}e^{j\phi}||_2^2$$ Here, $$x$$ and $$y$$ are vectors and $$\phi$$ is a constant phase factor that applies to the all entries of $$y$$. I could not make any progress in this problem. If anyone can point me to a possible closed form solution that would be great.

• What did you try? This looks like a pretty standard optimization problem. Mar 12 at 20:15
• "I could not make any progress" is not a question. Mar 13 at 17:28
• The question is, if someone knows a closed form solution and if so can that particular person point it out. I might be able to solve it by myself but I want to take advantage of this particular website where its sole purpose is not to teach stuff, but also maybe sharing knowledge? I also do not feel like justify my "question". Thanks for your "answer" though. Mar 13 at 20:42

It seems to me that you can't do any better than taking the classical least-squares solution $$x = A^+y$$. To see that, replay the solution of the least-squares problem via SVD: take an SVD $$A=U\Sigma V^*$$, with $$\Sigma\in\mathbb{R}^{m\times n}$$ diagonal, and set $$z = V^*x$$ and $$w = U^* y$$. Then, $$z$$ solves $$\arg\min_{z,\phi} \|\Sigma z - w e^{j\phi}\|,$$ and this problem is a separable minimization problem in the entries of $$z$$ that is simple enough to solve by hand.
In particular, the objective function is the 2-norm of a vector with entries $$\sigma_i z_i - w_i e^{j\phi}$$ for $$i=1,2,\dots, r$$, $$r$$ being the rank of $$A$$, and $$-w_i e^{j\phi}$$ for $$i>r$$. The first $$r$$ entries become zero if one sets $$z_i = \frac{w_i}{\sigma_i e^{j\phi}}, \quad i=1,2,\dots,r \tag{*}$$ and the entries after that have constant absolute value independently of $$z$$ and $$\phi$$. So any pair $$(z,\phi)$$ that satisfies (*) is a minimizer.
In particular, one of the minimizers is $$x=A^+y$$, obtained by taking $$\phi=0$$ and $$z_i=0$$ for each $$i>r$$ in addition to the conditions (*). This is also a minimum-norm solution.