Yamabe's equation This is PDE Evans, 2nd edition: Chapter 9, Exericse 8(a).


  
*(a) Assume $n \ge 3$. Find a constant $c$ such that $$u(x) := (1+|x|^2)^{\frac{2-n}2}$$ solves Yamabe's equation $$-\Delta u = cu^{\frac{n+2}{n-2}} \quad \text{in }\mathbb{R}^n.$$ Note the appearance of the critical exponent $\frac{n+2}{n-2}$.
  

My work so far:
Given $u(x):= (1+|x|^2)^{\frac{2-n}2}$, we find that $$u^{\frac{n+2}{n-2}}=(1+|x|^2)^{-\frac{n+2}2}.$$
Also, I differentiate $u(x)$ to find $$u_{x_i}=(2-n)(1+|x|^2)^{-\frac n2} x_i.$$ I differentiate again to find \begin{align}
u_{x_i x_i} &= (2-n)\left[-n(1+|x|^2)^{-\frac{n+2}2} x_i^2 + (1+x^2)^{-\frac n2}\right] \\
&= (2-n)[-nx_i^2 +(1+x^2)](1+|x|^2)^{-\frac{n+2}2}.
\end{align}
Therefore, the negative Laplacian is
\begin{align}
-\Delta u = -\sum_{i=1}^n u_{x_i x_i}  
&= (n-2)[-n|x|^2 +n(1+x^2)](1+|x|^2)^{-\frac{n+2}2} \\
&= (n-2)n(1+|x|^2)^{-\frac{n+2}2}
\end{align}
Putting these altogether, Yamabe's PDE $-\Delta u=cu^{\frac{n+2}{n-2}}$ becomes $$(n-2)n(1+|x|^2)^{-\frac{n+2}2}=c(1+|x|^2)^{-\frac{n+2}2}.$$
This would mean that $$c=n(n-2).$$
I had fixed my work acordingly (see my revision history), so this is actually the answer. I do have a follow-up question here, though.

You should have $$u_{x_i x_i} = (2-n)\left[-n(1+|x|^2)^{-\frac{n+2}2} x_i^2 + (1+|x|^2)^{-\frac n2}\right].$$
That is, not $x_i$, but $x_i^2$ in the squred bracket. Therefore, we have
$$-\Delta u=-\sum_{i=1}^nu_{x_i x_i} = -(2-n)\left[-n(1+|x|^2)^{-\frac{n+2}2} |x|^2 + n(1+|x|^2)^{-\frac n2}\right]=n(n-2)(1+|x|^2)^{-\frac{n+2}2}$$
where the second equality follows from $|x|^2=\sum_{i=1}^nx_i^2$.
As you have calculated, $u^{\frac{n+2}{n-2}}=(1+|x|^2)^{-\frac{n+2}2}$. We have
$$-\Delta u=n(n-2)u^{\frac{n+2}{n-2}}.$$
