Let $A$ be a linear operator which acts on the vector space $V=\langle x_1,x_2, \ldots,x_n\rangle$ by permutation of the basis vectors. Suppose we know its eigenvalues ( some roots of unity ): $\lambda_1, \lambda_2, \ldots, \lambda_n.$
Now consider the vector space $V^{(2)} \subset {\rm Sym}^2 V$ generated by elements $x_i x_j, i<j,$ $\dim V^{(2)}=\binom{n}{2}.$ Let us expand the operator $A$ on $V^{(2)}$ by linearity and by $A(x_i x_j)=A(x_i)A(x_j)$. Denote the extension by $A^{(2)}$. It is clear that $A^{(2)}$ permutes the basis vectors of $V^{(2)}$ so $A^{(2)}$ is an endomorphism of $V^{(2)}$.
Question. What is the trace of the $A^{(2)}?$
By method of trial and error I have found a formula for the trace $$ {\rm Tr}(A^{(2)})=\sum_{i=1}^n\lambda_i^2+\sum_{i<j}\lambda_i \lambda_j-\sum_{i=1}^n \lambda_i $$ but I can't prove it. Any ideas?