We're studying about the maximum principle at this semester and the following is an exercise which has been assigned to us.
Let $U\subset \mathbb R^2$ open bounded and with smooth boundary. Also let $u\in \mathcal C^2(U) \cap \mathcal C^1(\bar U)$. Prove that for any solution $u\neq 0$ of $u_{xx} +u_{yy} -u^2 =0$ the maximum in not attained in the interior of $U$.
My thoughts about this exercise are that since the pde is equal to $\Delta u=u^2$, then for any non zero solution u, $\Delta u \gt 0\;\forall (x,y)\in U$ and so it's impossible for u to attain its maximum in the interior of $U$. Because if $\exists (x_0,y_0)\in U$ such as $u(x_0,y_0)=\max_{\bar U} u$, then $\Delta u(x_0,y_0) \le 0$ which is a contradiction. Finally since $u$ is continuous on compact set, its maximum will be attained on the boundary of $U$.
I wonder if the above is true. I feel like it was too simple to be this the correct answer. Am I missing something? If this is not the correct answer , could somebody give me some hints?
Thanks in advance!
Suppose that the maximum is attained in an interior point. Then the Hessian of $u$ (i.e. $\nabla\nabla u$) is a negative definite matrix. Among other things, it implies that the trace of this matrix is strictly negative: $$tr(\nabla \nabla u ) < 0.$$ On the other hand, we know that $$tr(\nabla \nabla u ) = \Delta u = u^2 \ge 0.$$ Contradiction.