【答案】 解： $|P|=\left|\begin{array}{ccc}-1 & 1 & 1 \\ 1 & 0 & 2 \\ 1 & 1 & -1\end{array}\right|=6 \neq 0$ ，所以矩阵 $P$ 可逆，于是有 $A=P \Lambda P^{-1}, \varphi(A)=P \varphi(\Lambda) P^{-1}$. 而 $\varphi(1)=0, \varphi(2)=10, \varphi(-3)=0$. 故 $\varphi(\Lambda)=\operatorname{diag}(0,10,0)$.
\begin{aligned} & \varphi(A)=P \varphi(\Lambda) P^{-1}=\left(\begin{array}{ccc} -1 & 1 & 1 \\ 1 & 0 & 2 \\ 1 & 1 & -1 \end{array}\right)\left(\begin{array}{ccc} 0 & & \\ & 10 & \\ & & 0 \end{array}\right) \frac{1}{|P|} P^* \\ & =\frac{10}{6}\left(\begin{array}{lll} 0 & 1 & 0 \\ 0 & 0 & 0 \\ 0 & 1 & 0 \end{array}\right)\left(\begin{array}{lll} A_{11} & A_{21} & A_{31} \\ A_{12} & A_{22} & A_{32} \\ A_{13} & A_{23} & A_{33} \end{array}\right)=\frac{5}{3}\left(\begin{array}{ccc} A_{12} & A_{22} & A_{32} \\ 0 & 0 & 0 \\ A_{12} & A_{22} & A_{32} \end{array}\right) \\ & \text { 而 } A_{12}=-\left|\begin{array}{cc} 1 & 2 \\ 1 & -1 \end{array}\right|=3, A_{22}=\left|\begin{array}{cc} -1 & 1 \\ 1 & -1 \end{array}\right|=0 \text {, } \\ & A_{32}=-\left|\begin{array}{cc} -1 & 1 \\ 1 & 2 \end{array}\right|=3 \text {, } \\ & \text { 所以 } \varphi(A)=\left(\begin{array}{lll} 5 & 0 & 5 \\ 0 & 0 & 0 \\ 5 & 0 & 5 \end{array}\right) \text {. } \\ & \end{aligned}