The problem I want to solve has this form:
\begin{equation} \begin{aligned} & \underset{\theta}{\text{minimize}} & & \sum_{k=1}^{K} \|g_k - \theta_k\|_2^2 \\ & \text{subject to} & & \| \theta_m - \theta_l \|_2^2 \leq \| x_m - x_l \|_2^2 , \quad 1 \leq m < l \leq K, \end{aligned} \end{equation}
($\theta_i$ are the variables to optimize over; $x_i$ and $g_i$ are constants; $\|.\|_2$ stands for the Euclidean norm)
Is there any closed-form for arbitrary $K$? Or an appropriate first-order iterative method which yields an approximate solution?