First let me define Difference multiset for a set of integers $$P=\{p_1,p_2, \dots,p_K\} ,\quad p_i \in\{1,2,\dots,N\},\quad p_i\ne p_j $$ as below: $$ D = \{p_i-p_j \mod N ,\quad i \ne j\} $$ I know that the minimum of $f(x)$ is same for all $P$'s having same difference multiset & and also the optimal $x$ (minimizing $f$) is same for all of them up to permutation of elements, where $f(x)$ is a real function which is defined:
$$\large f(x) = {\sum_{j=1}^K \sum_{k=1}^K x_j x_k e^{\frac{i2\pi l(p_j-p_k)}N} \over \left( \sum_{i=1}^K x_i\right)^2} $$ where $l$ is a constant integer and $x_i$'s are positive variables
I achieved this result from simulations. I'm looking for a proof or even a justification which helps me prove it.
I've also asked this on MO