# Hopf lemma

In mathematics, the Hopf lemma, named after Eberhard Hopf, states that if a continuous real-valued function in a domain in Euclidean space with sufficiently smooth boundary is harmonic in the interior and the value of the function at a point on the boundary is greater than the values at nearby points inside the domain, then the derivative of the function in the direction of the outward pointing normal is strictly positive. The lemma is an important tool in the proof of the maximum principle and in the theory of partial differential equations. The Hopf lemma has been generalized to describe the behavior of the solution to an elliptic problem as it approaches a point on the boundary where its maximum is attained.
In the special case of the Laplacian, the Hopf lemma had been discovered by Stanisław Zaremba in 1910. In the more general setting for elliptic equations, it was found independently by Hopf and Olga Oleinik in 1952, although Oleinik's work is not as widely known as Hopf's in Western countries. There are also extensions which allow domains with corners.

## Statement for harmonic functions

Let Ω be a bounded domain in R$^n$ with smooth boundary. Let f be a real-valued function continuous on the closure of Ω and harmonic on Ω. If x is a boundary point such that f(x) > f(y) for all y in Ω sufficiently close to x, then the (one-sided) directional derivative of f in the direction of the outward pointing normal to the boundary at x is strictly positive.

## Proof for harmonic functions

Subtracting a constant, it can be assumed that f(x) = 0 and f is strictly negative at interior points near x. Since the boundary of Ω is smooth there is a small ball contained in Ω the closure of which is tangent to the boundary at x and intersects the boundary only at x. It is then sufficient to check the result with Ω replaced by this ball. Scaling and translating, it is enough to check the result for the unit ball in R$^n$, assuming f(x) is zero for some unit vector x and f(y) < 0 if |y| < 1.
By Harnack's inequality applied to −f
    $\displaystyle {-f(rx)\geq -{1-r \over (1+r)^{n-1}}f(0),}$
for r < 1. Hence
    $\displaystyle {{f(x)-f(rx) \over 1-r}={-f(rx) \over 1-r}\geq -{1 \over (1+r)^{n-1}}f(0)>-{f(0) \over 2^{n-1}}>0.}$
Hence the directional derivative at x is bounded below by the strictly positive constant on the right hand side.

## General discussion

Consider a second order, uniformly elliptic operator of the form
    $Lu=a_{ij}(x){\frac {\partial ^{2}u}{\partial x_{i}\partial x_{j}}}+b_{i}(x){\frac {\partial u}{\partial x_{i}}}+c(x)u,\qquad x\in \Omega .$
In particular, the smallest eigenvalue of the real symmetric matrix $a_{ij}(x)$ is bounded from below by a positive constant that is independent of $x$. Here $\Omega$ is an open, bounded subset of $\mathbb {R} ^{n}$ and one assumes that $c\leq 0$.
The Weak Maximum Principle states that a solution of the equation $Lu=0$ in $\Omega$ attains its maximum value on the closure ${\overline {\Omega }}$ at some point on the boundary $\partial \Omega$. Let $x_{0}\in \partial \Omega$ be such a point, then necessarily
    ${\frac {\partial u}{\partial \nu }}(x_{0})\geq 0,$
where $\partial /\partial \nu$ denotes the outer normal derivative. This is simply a consequence of the fact that $u(x)$ must be nondecreasing as $x$ approach $x_{0}$. The Hopf Lemma strengthens this observation by proving that, under mild assumptions on $\Omega$ and $L$, we have
    ${\frac {\partial u}{\partial \nu }}(x_{0})>0.$
A precise statement of the Lemma is as follows. Suppose that $\Omega$ is a bounded region in $\mathbb {R} ^{2}$ and let $L$ be the operator described above. Let $u$ be of class $C^{2}(\Omega )\cap C^{1}({\overline {\Omega }})$ and satisfy the differential inequality
    $Lu\geq 0,\qquad {\textrm {in}}~\Omega .$
Let $x_{0}\in \partial \Omega$ be given so that $0\leq u(x_{0})=\max _{x\in {\overline {\Omega }}}u(x)$. If (i) $\Omega$ is $C^{2}$ at $x_{0}$, and (ii) $c\leq 0$, then either $u$ is a constant, or ${\frac {\partial u}{\partial \nu }}(x_{0})>0$, where $\nu$ is the outward pointing unit normal, as above.
The above result can be generalized in several respects. The regularity assumption on $\Omega$ can be replaced with an interior ball condition: the lemma holds provided that there exists an open ball $B\subset \Omega$ with $x_{0}\in \partial B$. It is also possible to consider functions $c$ that take positive values, provided that $u(x_{0})=0$. For the proof and other discussion, see the references below.