1 Introduction

In this paper, we study the size of the zero set of solutions u of a certain class of elliptic PDEs (see Sect. 2.1) near the boundary of a Lipschitz domain. Assume \(\Omega \subset {\mathbb {R}}^d\) is a Lipschitz domain with small Lipschitz constant and \(\Sigma \) is an open set of the boundary \(\partial \Omega \) where u vanishes. We investigate the dimension of the set \({\mathcal {S}}_{\Sigma }'(u) = \{x \in \Sigma ~|~ u^{-1}(\{0\}) \cap B(x,r)\cap \Omega \ne \varnothing , ~\forall r>0\}\), the set where u changes sign in every neighborhood.

In a more regular setting, for example in the case \(\Omega \) is a \(C^{1,{\text {Dini}}}\) domain (see [2, 9, 19, 21, 22] for the definition) and u is harmonic, \({\mathcal {S}}_{\Sigma }'(u)\) coincides with the usual singular set at the boundary of u: \({\mathcal {S}}_{\Sigma }(u) = \{x \in \Sigma ~|~ |\nabla u(x)| = 0\}\) (see Proposition 1.9). Note that all \(C^{1,\alpha }\) domains (for any \(\alpha >0\)) are \(C^{1,{\text {Dini}}}\) and all \(C^{1,{\text {Dini}}}\) domains are \(C^1\), but the converse is not true. Nonetheless, in the case where \(\Omega \) is a Lipschitz domain, \(\nabla u(x)\) (or \(\partial _\nu u\)) only exists in \(\Sigma \) in a weaker sense (see “Appendix A”) as far as we know, which anticipates that we will not be able to find fine estimates of the size and dimension of \({\mathcal {S}}_{\Sigma }(u)\) (see Sect. 9). The situation is different for \({\mathcal {S}}_{\Sigma }'(u)\), for which we prove the following Minkowski dimension estimate:

Theorem 1.1

Let \(\Omega \subset {\mathbb {R}}^d\) be a Lipschitz domain, and let A(x) be a uniformly elliptic symmetric matrix with Lipschitz coefficients defined on \({\overline{\Omega }}\). Let B be a ball centered in \(\partial \Omega \) and suppose that \(\Sigma = B \cap \partial \Omega \) is a Lipschitz graph with slope \(\tau <\tau _0\), where \(\tau _0\) is some positive constant depending only on d and the ellipticity of A(x). Let \(u\not \equiv 0\) be a solution of \({\text {div}}(A(x)\nabla u(x)) = 0\) in \(\Omega \), continuous in \({\overline{\Omega }}\) that vanishes in \(\Sigma \). Then there exists some small constant \(\epsilon _1(d) > 0\) and a family of open balls \((B_i)_i, ~i \in {\mathbb {N}}\) centered on \(\Sigma \) such that

  1. (1)

    \(u|_{B_i \cap \Omega }\) is either strictly positive or negative, for all \(i \in {\mathbb {N}}\),

  2. (2)

    \(K\backslash \bigcup _i B_i\) has Minkowski dimension at most \(d-1-\epsilon _1\) for any compact \(K \subset \Sigma \).

Moreover, in the planar setting (\(d=2\)), the set \(K\backslash \bigcup _i B_i\) is finite for any compact \(K\subset \Sigma \).

Recall that the upper Minkowski dimension of a set \(E \subset {\mathbb {R}}^{d-1}\) can be defined as

$$\begin{aligned} {\text {dim}}_{\overline{{\mathcal {M}}}} E = \limsup _{j\rightarrow \infty } \frac{\log (\#\{\hbox {dyadic cubes}\, Q\, \hbox {of side length} \,2^{-j}\, \hbox {that satisfy} \,Q \cap E \ne \varnothing \})}{j\log 2}.\nonumber \\ \end{aligned}$$
(1.1)

The previous result gives the following corollary:

Corollary 1.2

Assume \(\Omega \subset {\mathbb {R}}^d\), \(\Sigma \), A(x), \(\tau <\tau _0\), and \(u\not \equiv 0\) as in the statement of Theorem 1.1. Then, there exists a constant \(\epsilon _1(d)>0\) such that

$$\begin{aligned} {\text {dim}}_{\overline{{\mathcal {M}}}} \left( {\mathcal {S}}_\Sigma '(u) \cap K \right) \le d-1-\epsilon _1 \end{aligned}$$

for any compact set \(K\subset \Sigma \).

Remark 1.3

We remark that Theorem 1.1 and Corollary 1.2

  • are new even in the harmonic case as the set \({\mathcal {S}}_\Sigma '(u)\) has not been well studied before (as far as I know),

  • are valid for harmonic functions in Riemannian manifolds with Lipschitz boundary (with small Lipschitz constant depending on the metric),

  • include the case when \(\Omega \) is a \(C^1\) domain, situation where not too much is known either,

  • give Hausdorff dimension estimates for the set \({\mathcal {S}}_{\Sigma }'(u)\) by taking an exhaustion of \(\Sigma \) by compact sets. Note that Hausdorff dimension estimates are weaker than Minkowski dimension estimates but these were not known either.

Remark 1.4

Some of the results of the present paper suggest that the set \({\mathcal {S}}_\Sigma '(u)\) might be a natural substitute of the usual singular set \({\mathcal {S}}_\Sigma (u)\) in the case of Lipschitz domains (and rougher). These results are the fact that \({\mathcal {S}}_\Sigma (u) = {\mathcal {S}}_\Sigma '(u)\) in the case \(\Omega \) is a \(C^{1,{\text {Dini}}}\) domain (Proposition 1.9), the existence of an example of a Lipschitz domain where \({\text {dim}}_{{\mathcal {H}}} {\mathcal {S}}_\Sigma (u)=d-1\) and no better (see Sect. 9), and Corollary 1.2 showing that better dimension estimates are true for \({\mathcal {S}}_\Sigma '(u)\).

Moreover, we show an upper bound estimate on the size of the zero set of u on balls centered at \(\Sigma \) in terms of the frequency function N(xr) (see Definition 3.3):

Theorem 1.5

Assume \(\Omega \), \(\Sigma \), A(x), \(\tau <\tau _0\), and \(u\not \equiv 0\) as in the statement of Theorem 1.1. Let \(x\in \Sigma \) and \(0<r<r_0\) with \( r_0\) depending on \({\text {dist}}(x, \partial \Omega \backslash \Sigma )\), the Lipschitz constant \(L_A\) and the ellipticity \(\Lambda _A\) of A(x), and d. There exists \({\tilde{x}} \in \Omega \) such that \(\vert x-{\tilde{x}}\vert \approx _{\Lambda _A} {\text {dist}}({\tilde{x}}, \partial \Omega ) \approx _{\Lambda _A} r\) and

$$\begin{aligned} {\mathcal {H}}^{d-1}(\{u = 0\} \cap B(x,r) \cap \Omega ) \le C r^{d-1} (N({\tilde{x}}, S r)+1)^\alpha \end{aligned}$$

for some large S depending on \(L_A, \Lambda _A\) and d, and some \(\alpha \ge 1\) depending on d.

The precise \({\tilde{x}}\) appearing in the statement of Theorem 1.5 is the center of a certain dyadic cube related to a Whitney cube decomposition of \(\Omega \) but we have freedom in choosing it. For more details see Sect. 4.1 and Remark 6.5. This result is analogous to Theorem 2 in [28] for a more general class of functions but with a worse exponent. Further, we briefly discuss the application of this theorem to the study of the zero set of Dirichlet eigenfunctions of the operator \({\text {div}}(A\nabla \cdot )\) in \(\Omega \) in Sect. 6.6. See [28] for more background on this result and its applications in the harmonic case.

Let us give some historical background for the results of this paper. L. Bers asked the following question. Consider a harmonic function u in the upper half-plane \({\mathbb {R}}^d_+\), \(C^1\) up to the boundary such that there exists \(E \in \partial {\mathbb {R}}^d_+ = {\mathbb {R}}^{d-1}\) where \(u = \vert \nabla u \vert = 0\) on E. Does \({\text {measure}}_{d-1}(E)>0\) imply \(u \equiv 0\)? This question has positive answer in the plane, thanks to the subharmonicity of \(\log |\nabla u|\). But in \({\mathbb {R}}^d_+,~ d \ge 3\), there are examples constructed by Bourgain and Wolff [6] which give a negative response in general.

A related conjecture by Lin [23] which is still open is the following:

Conjecture

Let \(\Omega \subset {\mathbb {R}}^d\) be a Lipschitz domain and \(\Sigma = B\cap \partial \Omega \) for some ball B centered in \(\partial \Omega \). Let u be a harmonic function in \(\Omega \) and continuous up to the boundary that vanishes in \(\Sigma \). If the set where \(\partial _\nu u = 0\) in \(\Sigma \) has positive surface measure, then u must be identically zero.

This conjecture was proved in the \(C^{1,1}\) case in [23], where it was also shown that \({\mathcal {S}}_{\Sigma }(u)\) is a \((d-2)\)-dimensional set (see also [7] for more quantitative estimates). V. Adolfsson, L. Escauriaza and C. Kenig also gave a positive answer to the conjecture in [3] in the case \(\Omega \) is a convex Lipschitz domain. Their work was followed by Kukavica and Nyström [19], and Adolfsson and Escauriaza [2] where the conjecture is solved in the case \(\Omega \) is \(C^{1, {\text {Dini}}}\). Moreover, in [2] it is also proved that \({\mathcal {S}}_{\Sigma }(u)\) has Hausdorff dimension at most \(d-2\).

In the interior of the domain, the singular and critical sets of u have been extensively studied too. In particular, the recent results from Naber and Valtorta [30] are remarkable: they find \((d-2)\)-dimensional Minkowski content bounds and prove they are \((d-2)\)-rectifiable with the introduction of a new quantitative stratification. Some of their techniques have been adapted to study the Minkowski content of the singular set at the boundary in the convex Lipschitz case by McCurdy [29] and in the \(C^{1, {\text {Dini}}}\) by Kenig and Zhao [21]. Unfortunately, the methods relying on pointwise monotonicity that have been commonly used to study this problem are no longer useful in general Lipschitz domains, and new ideas are needed in this case. The conjecture of F.-H. Lin saw no further progress until X. Tolsa proved the result for harmonic functions in Lipschitz domains with small Lipschitz constants in [33]. His proof uses the new powerful methods developed by A. Logunov and E. Malinnikova (see [24, 25, 27]) to study zero sets of Laplace eigenfunctions in compact Riemannian manifolds. These techniques are used on the boundary of the domain \(\Omega \) with the trade-off of restricting its Lipschitz constant. This idea from [33] has also been successfully used by Logunov et al. [28] to study the zero set of Dirichlet Laplace eigenfunctions in Lipschitz domains with small Lipschitz constant. In [28], the authors also develop novel methods to control the zero set near the boundary that will be relevant in the present paper.

The main tool used in this paper is Almgren’s frequency function (see Definition 3.3), a quantity that controls the doubling properties of the \(L^2\) averages of u in spheres. This function was also used in most of the works mentioned in this introduction. Our proof of Theorem 1.1 requires two technical lemmas. One is Lemma 4.1, an adaptation of Lemma 3.1 - Key lemma from [33] and it controls the behavior of the frequency function at points in \(\Omega \) near the boundary (see also Lemma 7 from [28]). The other is Lemma 5.1, inspired by Lemma 8 - Second hyperplane lemma: cubes without zeros from [28] and it controls the size of balls centered at the boundary that contain no zeros of u. Both results were originally proved only for harmonic functions, hence we first extend them for solutions of second order linear elliptic PDEs in divergence form. Afterwards, we combine both lemmas in a new combinatorial argument that controls the size of the zero set of u near the boundary. We remark that the extension of Lemma 8 from [28] to the elliptic case presents many difficulties and it might be interesting on its own.

Theorem 1.1 allows us to prove an analogous unique continuation at the boundary result to the one in [33] for more general elliptic PDEs in divergence form:

Corollary 1.6

Assume \(\Omega \), \(\Sigma \), A(x), \(\tau <\tau _0\), and \(u\not \equiv 0\) as in the statement of Theorem 1.1. The set \(\{x \in \Sigma ~|~ \partial _\nu u(x) = 0\}\) has \((d-1)\)-Hausdorff measure 0.

Observe that the assumption that u vanishes continuously in \(\Sigma \) implies that \(\nabla u\) exists \(\sigma \)-a.e. as a non-tangential limit in \(\Sigma \), and \(\nabla u = (\partial _\nu u) \nu \in L^2_{\text {loc}}(\sigma )\). Here \(\sigma \) stands for the surface measure restricted to \(\Sigma \) and \(\nu \) is the outer unit normal (see Remark 3.7 and “Appendix A”).

The proof of Corollary 1.6 uses that the elliptic measure \(\omega _A\) associated to the elliptic operator \({\text {div}}(A\nabla \cdot )\) is an \({\mathcal {A}}_\infty \) Muckenhoupt weight with respect to \(\sigma \) (see Definiton 7.1) and that, since \(\vert u\vert \) is locally comparable to a Green function near most points of \(\Sigma \) (thanks to not changing sign in a neighborhood), \(\partial _\nu u\) is comparable to \(d\omega _A/d\sigma \).

Theorem 1.1 also has a second corollary that controls the vanishing order of the zeros in the set where u does not change sign nearby.

Definition 1.7

The vanishing order of the zero at a point \(x \in \Sigma \) is defined as the supremum of the \(\alpha >0\) such that there exist \(C_\alpha >0\) finite and \(r_0>0\) satisfying

Corollary 1.8

Assume \(\Omega \), \(\Sigma \), A(x), \(\tau <\tau _0\), and \(u\not \equiv 0\) as in the statement of Theorem 1.1. There exists some small constant \(\epsilon _2>0\) depending on d, the Lipschitz constant \(\tau \) of \(\Sigma \), and the ellipticity \(\Lambda _A\) of the matrix A(x) such that for all \(x\in \Sigma \) outside a set of Hausdorff dimension \(d-1-\epsilon _1\), the vanishing order of u at x is smaller than \(1+\epsilon _2\). Moreover, for all \(x \in \Sigma \), the vanishing order of u at x is greater than \(1-\epsilon _2\).

This corollary is proved by comparing u locally (in the neighborhoods where it does not change sign) with the Green function of a certain cone with angular opening related to the Lipschitz constant \(\tau \) of \(\Sigma \).

In Sect. 9 we provide an example showing that Corollary 1.6 cannot be improved in the sense of Hausdorff dimension estimates. This contrasts with the higher regularity case (\(C^{1,\text {Dini}}\)) where the set \({\mathcal {S}}_\Sigma (u)\) is known to be \((d-2)\)-rectifiable and, a fortiori, has Hausdorff dimension at most \(d-2\) (see [21]). Finally, in Sect. 10, we prove the following proposition relating \({\mathcal {S}}_\Sigma (u)\) and \({\mathcal {S}}_\Sigma '(u)\) in the smooth case.

Proposition 1.9

Let \(\Omega \subset {\mathbb {R}}^d\) be a \(C^{1,{\text {Dini}}}\) domain, B be a ball centered in \(\partial \Omega \), and \(\Sigma = B\cap \partial \Omega \). Let u be a harmonic function defined in \(\Omega \), continuous in \({\overline{\Omega }}\) that vanishes in \(\Sigma \). Then \({\mathcal {S}}_{\Sigma }(u)\) coincides with \({\mathcal {S}}_{\Sigma }'(u)\).

The proof of the proposition follows from a local expansion of u as the sum of a homogeneous harmonic polynomial and an error term of higher degree proved in [22].

1.1 Further questions

We present some open questions related to the previous results:

  • Is it true that \({\text {dim}}_{\overline{{\mathcal {M}}}} {\mathcal {S}}_\Sigma '(u)\cap K\) is at most \(d-2\) for any compact \(K\subset \Sigma \) (\(\epsilon _1 \equiv 1\))? What about the (slightly) easier case where \(\Omega \) is a \(C^1\) domain?

  • Is the set \({\mathcal {S}}_\Sigma '(u)\) \((d-2)\)-rectifiable?

  • Do these estimates hold for general Lipschitz domains? For the moment, even the conjecture of Lin is still open.

  • Can there exist points with vanishing order \(\infty \) in \(\Sigma \) in the Lipschitz case? Thanks to the results of [2, 19, 21, 22] we know this cannot happen in the \(C^{1,{\text {Dini}}}\) case.

1.2 Outline of the paper

In Sects. 2 and 3, we present some notation, tools and ideas that will be used throughout the paper (often without reference). The main aim of Sect. 4 is the proof of Lemma 4.1, although in Sect. 4.1 we construct a Whitney cube structure to \(\Omega \) that will be used during the sections following after. Section 5 is devoted to Lemma 5.1. Both lemmas are then combined in a combinatorial argument in Sect. 6 to prove Theorems 1.1 and 1.5. In Sect. 6, we also briefly discuss the application of Theorem 1.5 to the study of the zero set of certain class of eigenfunctions. The rest of the paper is spent on the proofs of Corollaries 1.61.8, the example of a Lipschitz domain and harmonic function u with “large" \({\mathcal {S}}_\Sigma (u)\), and the equality \({\mathcal {S}}_{\Sigma }(u) = {\mathcal {S}}_{\Sigma }'(u)\) in the \(C^{1,{\text {Dini}}}\) case. This last part does not require the Whitney cube structure or Lemmas 4.1 and 5.1. In “Appendix A”, we discuss the existence of the non-tangential limit of \(\nabla u\) in \(\Sigma \).

2 Lipschitz domains with small constant and some properties of elliptic PDEs

Notation: the letters \(C, c, c', {\tilde{c}}\) are used to denote positive constants that depend on the dimension d and whose values may change on different proofs. The constants \(c_H\) and \(C_N\) retain their values. The notation \(A\lesssim B\) is equivalent to \(A \le CB\), and \(A \sim B\) is equivalent to \(A \lesssim B \lesssim A\). Sometimes, we will also use the notation \(A(x) = B(x) + O(x)\) to denote that \(|A(x) - B(x)| \lesssim |x|\).

In the whole paper, we assume that \(\Omega \), \(\Sigma \), and \(u\not \equiv 0\) are as in Theorem 1.1. Moreover, we assume that \(\Sigma \) is a Lipschitz graph with Lipschitz constant \(\tau \) with respect to the hyperplane \(H_0 := \{x_d = 0\}\) and that locally \(\Omega \) lies above \(\Sigma \).

Remark 2.1

Note that a \(C^1\) domain is a Lipschitz domain with local Lipschitz constant as small as we need. In particular, Theorems 1.1 and 1.5, and its corollaries are valid for \(C^1\) domains.

Remark 2.2

The Lipschitz constant of \(\Omega \) is invariant by rescalings. If we consider a more general (anisotropic) scaling given by multiplication by a positive definite symmetric matrix with ellipticity \({\tilde{\Lambda }}\), then the Lipschitz constant of \(\Sigma \) changes by a factor of at most \({\tilde{\Lambda }}^2\).

2.1 Divergence form elliptic PDEs with Lipschitz coefficients

The function u we study solves \({\text {div}}(A(x)\nabla u(x)) = 0\) weakly in \(\Omega \) where the matrix A(x) satisfies that

  • A(x) is symmetric.

  • There exists \(\Lambda _A>1\) such that \(\Lambda _A^{-1} \vert y \vert ^2 \le (A(x)y,y) \le \Lambda _A\vert y\vert ^2\) for all \(x\in {\overline{\Omega }}, y\in {\mathbb {R}}^d\) (uniform ellipticity).

  • There exists a Lipschitz constant \(L_A > 0\) such that \(|A_{ij}(x)-A_{ij}(y)| \le L_A |x-y|\) (Lipschitz coefficients).

By standard elliptic PDE theory (see [13, 16] for example), we know that \(u \in C^{1,\alpha }\) in any ball with closure inside \(\Omega \) for any \(0<\alpha <1\). Also \(u \in W^{1,2}(\Omega )\) and \(u \in W^{2,2}(\Omega ')\) for any compactly embedded subdomain \(\Omega ' \subset \subset \Omega \).

We extend the function u by 0 outside of \({\overline{\Omega }}\) so that it is continuous through \(\Sigma \). We also extend the matrix A(x) in a way that it preserves the ellipticity \(\Lambda _A\) and Lipschitz \(L_A\) constants up to a constant factor (the particular extension we choose will not matter). In particular, note that the absolute value of the extended function |u| is a subsolution in balls B such that \(B\cap \partial \Omega \subset \Sigma \). This means that

2.2 Modifying the domain and A(x)

Remark 2.3

Throughout this paper, we will require at different points the constants \(\max (\Lambda _A-1,1-\Lambda _A^{-1})\) and \(L_A\) to be very small. We can obtain this by exploiting the fact that our considerations are local. Indeed, we can cover our initial domain \(\Omega \) by a finite family of “small" domains and prove the results on the introduction on each one separately.

By “zooming" on a small domain, we decrease the Lipschitz constant \(L_A\) of the matrix. By rescaling the domain by multiplication with an adequate matrix, we can force \(A(x) = I\) at a particular point x. This, in addition to the small Lipschitz constant \(L_A\) of the new matrix, implies small ellipticity \(\Lambda _A\) (we will show this below). Note, though, that this last operation changes the Lipschitz constant \(\tau \) of \(\Sigma \). For this reason, in the statement of Theorem 1.1, \(\tau _0\) depends on the ellipticity of A(x). Intuitively, we use the Lipschitz regularity of A(x) to exploit that, in small scales, A(x) is very close to a constant matrix.

Let us show the effects of “zooming" and rescaling the domain when the domain is a ball. Suppose u solves weakly \({\text {div}}(A\nabla u)=0\) in a ball \(B_R\) for some \(R<1\), that is, for all \(\phi \in C_c^1 (B_R)\) we have

If we “zoom" in on the origin by considering the function \({\tilde{u}}(y) = u(Ry)\) defined on \(B_1\), we can show it satisfies

where \({\tilde{A}}(y) = A(Ry)\). Notice that \({\tilde{A}}(y)\) has improved Lipschitz constant \(R \cdot L_A < L_A\).

Now suppose that \(A(0) \ne I\) and we want to change the function, the domain and the equation so that “\(A(0) = I\)" for the solution of the new equation.

Consider \({\tilde{u}}(x) = u({\tilde{S}}x)\) defined in \({\tilde{S}}^{-1}B_R\) where \({\tilde{S}}\) is the symmetric positive definite square root of A(0) and \(B_R\) is a ball centered at the origin of radius \(R>0\). Then, for all \({\tilde{\phi }}(x) \in C_c^\infty ({\tilde{S}}^{-1}B_R)\), we have

where \(\phi ({\tilde{S}}x) = {\tilde{\phi }}(x)\). This implies that \({\tilde{u}}\) is a weak solution of the equation \( {\text {div}}(A_{{\tilde{S}}}(x)\nabla {\tilde{u}} )=0\) in \({\tilde{S}}^{-1}{B_R}\) where \(A_{{\tilde{S}}}(x) := {\tilde{S}}^{-1}A({\tilde{S}}x){\tilde{S}}^{-1}\).

Properties of the new matrix \(A_{{\tilde{S}}}(x)\):

  • Observe that \(A_{{\tilde{S}}}(0) = {\tilde{S}}^{-1}A(0){\tilde{S}}^{-1} = I\).

  • The coefficients of \(A_{{\tilde{S}}}(x)\) are also Lipschitz with constant \(L_{A_{{\tilde{S}}}}\) and the ratio between the Lipschitz constants of \(A_{{\tilde{S}}}\) and A can be bounded above and below by positive constants depending only on d and \(\Lambda _A\).

  • \(A_{{\tilde{S}}}(x)\) is uniformly elliptic with ellipticity constant bounded by \(\min (\Lambda _A^2,L_{A_{{\tilde{S}}}} \text {diam}({\tilde{S}}^{-1}B_R) d)\). Indeed, the largest and smallest eigenvalues \(\lambda _\text {max}\) and \(\lambda _\text {min}\) of \({A_{{\tilde{S}}}(z)}\) at a point \(z\in {\tilde{S}}^{-1}B_R\) satisfy

    $$\begin{aligned} \max (\lambda _\text {max} - 1, 1-\lambda _\text {min})&= \Vert A_{{\tilde{S}}}(z) - I \Vert _2 \le \Vert A_{{\tilde{S}}}(z) - I \Vert _F = \sqrt{\sum _{i,j} |a_{{\tilde{S}},i,j}(z) - \delta _{i,j}|^2} \\&\le L_{A_{{\tilde{S}}}} |z| d \le L_{A_{{\tilde{S}}}} \text {diam}({\tilde{S}}^{-1}B_R) d \end{aligned}$$

    where \(\Vert \cdot \Vert _F\) is the Frobenius norm, \(\Vert \cdot \Vert _2\) is the spectral norm, and \(\delta _{i,j}\) is the Kronecker delta.

3 Frequency function for solutions of elliptic PDEs in divergence form

Let \(x \in \Omega \cup \Sigma \) such that \(A(x) = I\). For \(r>0\) such that \(B_r(x) \cap \partial \Omega \subset \Sigma \), we denote \(\mu _x(y) := (A(y) (y-x) , y-x)/\vert y-x \vert ^2\) and

where \(\hbox {d}\sigma \) is the surface measure of the ball. Note that the quantity H(xr) is nonnegative. To simplify the notation we will assume from now on that x is the origin and we will write \(H(r) := H(x,r)\) and \(\mu (y) := \mu _x(y)\).

Remark 3.1

Observe that \(\Lambda _A^{-1}\le \mu (y) \le \Lambda _A\) and, since A has Lipschitz coefficients, we have \(|\mu (y) - 1| \lesssim L_A |y|\), \(\Vert A(y) - I\Vert _2 \lesssim L_A |y|\), and \(|\text {tr}A(y) - d| \lesssim L_A |y|\).

We also denote

Note that I(xr) is also nonnegative since A is positive definite. Moreover, I(xr) is finite thanks to Caccioppoli’s inequality supposing \(B_r(0)\cap \partial \Omega \subset \Sigma \). As before, we will write \(I(r):=I(x,r)\).

Proposition 3.2

Assume \(0\in \Omega \cup \Sigma \) and \(A(0) = I\). For \(r>0\) such that \(B_r \cap \partial \Omega \subset \Sigma \), the derivative of H(r) is

$$\begin{aligned} H'(r) = 2I(r) + O(L_A H(r)). \end{aligned}$$

As a consequence there exists some constant \(c>0\) such that

$$\begin{aligned} H'(r) \ge -c L_A H(r) . \end{aligned}$$

For the rest of this paper, we denote \(c_H := c L_A\). In particular, \(H(r)e^{c_H r}\) is a nondecreasing function of r. Note that in the harmonic case, \(c_H = 0\) and H is nondecreasing (which is also a corollary of the subharmonicity of \(|u|^2\)).

Note that the proof of Proposition 3.2 is quite simple in the case \(B(0,r) \cap \partial \Omega = \varnothing \). But in our setting we require some extra considerations to apply the divergence theorem in balls touching the boundary since u only belongs in \(W^{1,2}(B(0,r)\cap \Omega )\). To address this problem, we use “Appendix A” and follow the ideas of [33] in the harmonic case.

Proof

First, using that \(u \in W^{1,2}(B(0,r))\), we apply the divergence theorem to obtain

Using Remark 3.1, we expand the term inside the integral as

$$\begin{aligned} {\text {div}}(|u|^2 A(x) x)&= 2u (\nabla u, A(x)x) + |u|^2 \underbrace{\text {tr}(A(x))}_{d + O(L_A |x|)} + |u|^2 \underbrace{\sum _{i,j} (\partial _i a_{ij})x_j}_{O(L_A |x|)} \\&=: 2u (\nabla u, A(x)x) + d|u|^2 \mu (x) + \underbrace{f(x)}_{O(L_A |x|)}|u|^2. \end{aligned}$$

We compute (formally) the derivative of H:

Note that the only problematic term is . Observe though, that exists and is finite for almost every r since is finite. Nonetheless, using the divergence theorem, we show that for all \([a,b]\subset [0,{\text {dist}}(0,\partial \Omega \backslash \Sigma ))\):

where \({\mathcal {A}}(0,a,b)\) is the annulus \(B(0,b)\backslash B(0,a)\) for \(0<a<b\). Thus, we have the identity for \(H'(r)\) for almost every r.

Now we want to prove that

We denote \(\Sigma _\epsilon = \Sigma + \epsilon e_d\) and \(\Omega _\epsilon = \Omega + \epsilon e_d\) for small \(\epsilon >0\) where \(e_d = (0,\ldots ,0,1)\) and we have

from the fact that u vanishes continuously in \(\Sigma \) and \(\nabla u\) converges as a non-tangential limit in \(L^2_{{\text {loc}}}(\Sigma )\), as shown in “Appendix A”.

Now, since \(u\in W^{2,2}(B_r\cap \Omega _\epsilon )\), we may use divergence’s theorem and that u solves \({\text {div}}(A\nabla u)=0\) to obtain

Finally, the limit as \(\epsilon \rightarrow 0\) of the last term exists because \(u\in W^{1,2}(B_r)\).

Summing up, we have

with the second term being \(O(L_A H(r))\). \(\square \)

Definition 3.3

Assume \(x\in \Omega \cup \Sigma \) and \(A(x) = I\). For \(r>0\) such that \(B_r(x) \cap \partial \Omega \subset \Sigma \) we define the Almgren’s frequency function as

$$\begin{aligned} N(x,r) := r\frac{I(x,r)}{H(x,r)}. \end{aligned}$$

We will assume, as before, that x is the origin and we will write \(N(r) := N(x,r)\).

The following geometric lemma is essential to ensure good behavior for N(xr) in balls intersecting \(\Sigma \).

Lemma 3.4

Suppose that \(x \in \Omega \) and \(A(x) = I\). Assuming \(B_r(x)\cap \partial \Omega \subset \Sigma \), r is small enough (depending on \({\text {dist}}(x,\Sigma )\) and the Lipschitz constant \(L_A\) of A(y)), and the Lipschitz constant \(\tau \) of the domain is also small enough (depending on \({\text {dist}}(x,\Sigma )/r\) and \(L_A r\)), then

$$\begin{aligned} (\nu (y), A(y) (y-x)) \ge 0 \end{aligned}$$

for \({\mathcal {H}}^{d-1}\)-a.e. \(y\in \Sigma \cap B_r(x)\) where \(\nu \) is the outer unit normal to \(\partial \Omega \). In particular, if x is the origin, we have

Proof

Without loss of generality, we assume x is the origin, denote \(T={\text {dist}}(0,\Sigma )\) and suppose \(T\le r\). Otherwise, \(\Sigma \cap B_r = \varnothing \).

First, note that \(\Vert A(y) - I \Vert _2 \le C L_A r\) for all \(y \in B_r \cap \partial \Omega \) by the Lipschitz continuity of A. Using this, we obtain

$$\begin{aligned} (\nu (y), A(y) y)&= (\nu (y),y) + (\nu (y),(A-I)y)\\&\ge (\nu (y),y) - |y|C L_A r \\&= |y| \cos (\alpha ) - |y|C L_A r \end{aligned}$$

where \(\alpha \) is the angle between y and \(\nu (y)\).

If the domain were flat (\(\tau = 0\) and \(\Sigma \) were an open subset of a hyperplane) then all the points would have the same fixed normal vector \({\tilde{\nu }}\) and we would have \(\cos \alpha \ge \frac{T}{r} \). Since the domain is not flat (\(\tau \ne 0\)), we have that the normal vector \(\nu \) makes at most an angle of \(\arctan (\tau )\) with \({\tilde{\nu }}\). Using this we can bound from above \(\alpha \) by \(\arccos \frac{T}{r} + \arctan \tau \).

Now, assuming r is small enough so that

$$\begin{aligned} \frac{T}{r} > CL_A r \end{aligned}$$

and \(\tau \) is also small enough so that

$$\begin{aligned} \cos \left( \arccos \frac{T}{r} + \arctan \tau \right) \ge C L_A r, \end{aligned}$$

we obtain the desired inequality. \(\square \)

Definition 3.5

We will say that the origin \(0\in \Omega \cup \Sigma \) (assuming \(A(0)=I\)) and a radius r are admissible if they satisfy the assumptions of the previous lemma. If \(A(0)\ne I\), we will say that \(0\in \Omega \cup \Sigma \) and r are admissible if 0 and \(\Lambda _A^{1/2} r\) are admissible for the transformed domain \({\tilde{S}}^{-1}\Omega \) and the matrix \(A_{{\tilde{S}}}\) (see Remark 2.3). We can extend this definition to a point \(x\ne 0\) by translating the domain.

Remark 3.6

  1. (1)

    If \( {\text {dist}}(x,\Sigma ) > r\), we have that \(B_r \cap \partial \Omega = \varnothing \) and the integral is 0. In this case we also say that x and r are admissible.

  2. (2)

    If x and \(r'\) are admissible, then x and r are admissible for all \(0\le r < r'\).

  3. (3)

    In the case \(A(x) \ne I\), we can ensure admissibility if we impose

    $$\begin{aligned} \cos \left( \arccos \left( \Lambda _A^{-1} \frac{{\text {dist}}(x,\Sigma )}{r}\right) + \arctan (\Lambda _A\tau ) \right) \ge C L_A \Lambda _A^{1/2} r. \end{aligned}$$

    The reason is that, in the transformed domain, the Lipschitz constant \(\tau \) increases at most by a factor \(\Lambda _A\) and the distance from the point to \(\Sigma \) decreases at most by a factor \(\Lambda _A^{1/2}\).

Remark 3.7

Since the outer unit normal vector \(\nu \) is only defined \(\sigma \)-a.e. the derivative \(\partial _\nu u\) may not exist everywhere. Its existence, the non-tangential convergence, and the fact that \(\nabla u = (\nabla u, \nu ) \nu \) in \(L^2(\sigma )\) are proven in “Appendix A”.

We prove an almost monotonicity property for N(r) which was first observed in [14] in the interior of the domain.

Proposition 3.8

Assume 0 and \(r'\) are admissible, \(A(0) = I\), and the ellipticity constant \(\Lambda _A\) of A(x) is smaller than 2. Then there exists \(C_N>0\) depending on \(L_A\) such that \(e^{r C_N} N(r)\) is nondecreasing in the interval \((0,r')\).

For the proof of this proposition we will only keep track of the relation between the constant \(C_N\) and the Lipschitz constant \(L_A\). \(C_N\) also depends on the ellipticity constant \(\Lambda _A\) but, by assuming (for example) \(\Lambda _A < 2\), we can omit it. We may do so thanks to Remark 2.3. Notice also that \(C_N \equiv 0\) in the harmonic case.

Our proof is an adaptation of the one in [26] but with the inclusion of the case \(B_r\cap \partial \Omega \ne \varnothing \). We need special care when \(B_r\cap \partial \Omega \ne \varnothing \) as with the proof of Proposition 3.2. Again, we use “Appendix A” and follow the ideas of [33] in the harmonic case to circumvent these problems.

Proof

Fix a compact interval \(I \subset (0,r')\). We will show that the derivative of N(r) is positive a.e. \(r\in I\).

Since

and r is bounded away from 0, we have that I is absolutely continuous. Also note that we are only considering the case \(0\in \Omega \) (since we ask for admissibility). For this reason, H is of class \(C^1\) and bounded away from 0 and N is also absolutely continuous. The derivative is

$$\begin{aligned} N'(r) = \frac{( I(r)+r I'(r)) H(r) - r I(r) H'(r)}{ H(r)^2}. \end{aligned}$$

Let’s compute

The previous identity is true for a.e. \(r\in I\).

Let \(w(y) := \mu (y)^{-1} A(y)y\) be a vector field in \(\Omega \). Observe that \((w(y), y) = \vert y \vert ^2\) and that \(y/r = \nu \), the normal vector in \(\partial B_r\). We can rewrite \({\boxed {A}}\) as

To study \({\boxed {C}}\) we can use that \(B_r\cap \partial \Omega \subset \Sigma \) and, thus, \(\nabla u = (\nabla u,\nu )\nu \) on \(\Sigma \) (in the sense of non-tangential limits, see “Appendix A”).

Then, we have that

This term is a bit problematic and we will treat it later with the help of Lemma 3.4.

Let’s use the divergence theorem on \({\boxed {B}}\) (we do this in \(B_r\cap \Omega _\epsilon \) and then let \(\epsilon \rightarrow 0\), as in the proof of Proposition 3.2), obtaining

We have that

$$\begin{aligned} \begin{aligned} \text {div}(w(x) (A \nabla u, \nabla u ))&= \text {div}(w) (A \nabla u, \nabla u) + (w, \nabla (A \nabla u, \nabla u)) \\&=\text {div}(w) (A \nabla u, \nabla u) + 2(w, \text {Hess}(u)(A \nabla u)) + (A_{D,w}\nabla u, \nabla u) \end{aligned}\end{aligned}$$
(3.1)

where \(A_{D,w} = \{\sum _k (\partial _k a_{ij})w_k\}_{ij}\). Furthermore, \({\text {Hess}}(u)\) is symmetric and

$$\begin{aligned} {\text {Hess}}(u)(w) = \nabla (\nabla u, w) - (Dw)\nabla u. \end{aligned}$$

Let’s compute the integrals with all these terms in (3.1) one by one. First, we obtain

Using that u satisfies \({\text {div}}(A\nabla u) = 0\) in \(\Omega \), we get

We can rewrite the previous equation using the divergence theorem:

Using that \(\nabla u|_{\Sigma _\epsilon }\) converges to \((\nabla u,\nu )\nu \) on \(\Sigma \) in \(L^2_{{\text {loc}}}(\sigma )\) as \(\epsilon \rightarrow 0^+\) (see “Appendix A”), we get

where the last term on the right hand side coincides with \(\boxed {C}\) defined previously.

Remember that \(w(x) = \mu (x)^{-1} A(x)x\). Thus, we have the approximations \(Dw = I + O(L_A|x|)\), and \({\text {div}}(w) = d + O(L_A|x|)\) for some \(a>0\). We can use these estimates to show that

$$\begin{aligned} \lim _{\epsilon \rightarrow 0}\boxed {E} = r^{d-1}I(r) + O(L_A r^d I(r)). \end{aligned}$$

One of the terms we missed in (3.1) behaves as

and the other as

Summing everything up,

and we obtain

Since \(\boxed {C} \ge 0\) thanks to the fact that 0 and \(r'\) are admissible, and Lemma 3.4, we can use Cauchy–Schwarz inequality to show that the whole first term is positive. Indeed, note that from the proof of Proposition 3.2, we have

Thus, using Cauchy-Schwarz, we obtain

Therefore, there exists \( C \ge 0\) such that

$$\begin{aligned} N'(r) \ge - C L_A N(r) \end{aligned}$$

and we denote \(C_N := C L_A\). \(\square \)

3.1 Frequency function centered at arbitrary points

We have only considered H(xr) and N(xr) centered at points \(x\in \Omega \cup \Sigma \) where \(A(x) = I\). We can treat general points by making a change of variables such as the one in Sect. 2.2.

Assume \(A(0) \ne I\). Let \({\tilde{S}}\) be the symmetric positive definite square root of A(0), \({\tilde{u}}(x) = u({\tilde{S}}x)\), and \(A_{{\tilde{S}}} = {\tilde{S}}^{-1}A({\tilde{S}}x){\tilde{S}}^{-1}\). For the transformed equation \({\text {div}}(A_{{\tilde{S}}}\nabla {\tilde{u}})=0\) with \(A_{{\tilde{S}}}(0) = I\), we can compute

After some computations and a change of variables, we can check that it is equal (in the original domain) to

Remark 3.9

Note that \(\det {\tilde{S}}, (A(y)\nu (y), \nu (y))\) and \(r^{-1}|A(0)^{-1} y|\) can be upper and lower bounded by a constant depending only on the ellipticity constant \(\Lambda _A\).

In particular, by assuming \(\Lambda _A\) bounded, we have

On the other hand, we have

which, in the original domain, is equal to

This allows us to compute N(xr) for general points x. Beware that \(A_{{\tilde{S}}}\) may have different Lipschitz and ellipticity constants but this is not a problem since the change can be controlled as discussed in Sect. 2.2.

3.2 Auxiliar lemmas on the behavior of H(r) and N(r)

First, we will present a lemma that controls the growth of H(r) using N(r).

Lemma 3.10

Suppose \(0\in \Omega \cup \Sigma \), \(A(0)=I\), and \(\alpha >1\). Then

Moreover, if 0 and \(\alpha \rho \) are admissible, we have

$$\begin{aligned}{} & {} 2N(\rho ) (\log \alpha ) e^{-C_N(\alpha -1) \rho } -c_H(\alpha -1)\rho \le \\{} & {} \log \left( \frac{H(\alpha \rho )}{H(\rho )} \right) \le 2 N(\alpha \rho )(\log \alpha ) e^{C_N(\alpha -1) \rho } + c_H(\alpha -1)\rho . \end{aligned}$$

Proof

Using Propositions  3.2 and 3.8 on the interval \([\rho , \alpha \rho ]\), we can control

$$\begin{aligned} H'(r) \le 2I(r) + c_H H(r) = (2r^{-1}N(r) + c_H)H(r) \le (2r^{-1}N(\alpha \rho )e^{C_N(\alpha \rho -r)} + c_H)H(r). \end{aligned}$$

Analogously,

$$\begin{aligned} H'(r) \ge 2I(r) - c_H H(r) \ge (2r^{-1}N(\rho ) \hbox {e}^{C_N(\rho -r)} - c_H)H(r). \end{aligned}$$

Now we simply integrate \(H'/H\) in the interval \([\rho , \alpha \rho ]\). \(\square \)

The next lemma bounds \(L^2\) norms in annuli by H(r). We denote an annulus centered at x of outer radius \(r_2\) and inner radius \(r_1\) by \({\mathcal {A}}(x,r_1,r_2):= B(x,r_2)\backslash B(x,r_1)\).

Lemma 3.11

Suppose \(0\in \Omega \cup \Sigma \), \(r,\delta \ge 0\), \(B(0,r+\delta )\cap \partial \Omega \subset \Sigma \) and \(A(0)=I\). Then we have

(3.2)

Proof

Using polar coordinates, write

and use that \(\hbox {e}^{c_H r} H(r)\) is nondecreasing (Proposition 3.2), and \(|{\mathcal {A}}(0,r,r+\delta )| = |B_1|((r+\delta )^d-r^d)\). \(\square \)

In a similar fashion, if \(A(x_0)\ne I\) and we assume \(\Lambda _A\) bounded we obtain the following result.

Lemma 3.12

Suppose \(x_0 \in \Omega \cup \Sigma \) and \(B(x_0, \Lambda _A^{1/2} r) \cap \partial \Omega \subset \Sigma \). Then we have

Proof

Make a change of variables so that \(A(x_0) = I\). The ball \(B(x_0, r)\) is sent to an ellipsoide contained in the ball \(B(x_0, \Lambda _A^{1/2}r)\). Proceed as in the previous lemma by using that \(\mu \approx 1\). \(\square \)

The next lemma is a perturbation result for H(zr): it shows that we can bound H(0, r) by \(C H(z,r')\) if 0 and z are close compared to r. Moreover, it does not assume that \(A(z) = I\).

Lemma 3.13

Assume that \(0 \in \Omega \cup \Sigma \), \(A(0) = I\), \(\Lambda _A-1\) is small, \(z \in {\overline{\Omega }}\) such that \(|z| \le \gamma r\) with \(\gamma \in (0,1)\) and \(B_{100r}(z)\cap \partial \Omega \subset \Sigma \). Then for any \(\delta \in (0,10)\), we have

$$\begin{aligned} H(0,r) \le C(\gamma , \delta , d, r, L_A) H(z,\Lambda _A^{1/2}r(1+\gamma +\delta )) \end{aligned}$$

for some constant \(C>0\) depending on \(\gamma , \delta , d, r\), and \(L_A\).

We omit the dependence of C on \(\Lambda _A\) in this lemma.

Proof

Let \(\delta \in (0,10)\), then using Lemma 3.11, we get

Let \({\tilde{S}} := \sqrt{A(z)}\), \(\lambda _\text {min}\) be the minimum eigenvalue of \({\tilde{S}}\), \(\lambda _{\text {max}}\) be the maximum eigenvalue of \({\tilde{S}}\), \({\mathcal {A}}_0 := {\mathcal {A}}(0, r, r(1+\delta ))\), and \({\mathcal {A}}_z = {\mathcal {A}}(0, \lambda _\text {max}^{-1}(1-\gamma )r, \lambda _\text {min}^{-1}(1+\delta +\gamma )r)\). These two annuli are defined so that \(\mathcal {A}_0 \subset \{z\} + {\tilde{S}}{\mathcal {A}}_z\).

Moreover, we have the following estimates

$$\begin{aligned} \lambda _\text {min} \ge \max (\Lambda _A^{-1/2}, 1 - O(L_A \gamma r)) \end{aligned}$$

and

$$\begin{aligned} \lambda _\text {max} \le \min (\Lambda _A^{1/2}, 1 + O(L_A \gamma r)) \end{aligned}$$

which will be useful in the proof of the next lemma.

Now we can bound

where we have used that \({\mathcal {A}}_0 \subset \{z\} + {\tilde{S}}{\mathcal {A}}_z\) and \(\hbox {e}^{c_H |x|} = 1+O(L_A|x|)\).

We make the change of variables \(x = {\tilde{S}}y\), \(\hbox {d}x = (\det {\tilde{S}}) \hbox {d}y = (1+O(L_A \gamma r)) \,\hbox {d}y\) and integrate in polar coordinates to get

Finally, we use that \(\hbox {e}^{c_H r} H(r)\) is increasing to see that

Summing up, we obtain

$$\begin{aligned}{} & {} H(0,r) \le (1+O({L_A r (1+\delta )})) \\{} & {} \quad \frac{[((\lambda _\text {min}^{-1}(1+\gamma +\delta ))^d - (\lambda _\text {max}^{-1}(1-\gamma ))^d]}{(1+\delta )^d - 1} H(z, \lambda _{\text {min}}^{-1}(1+\gamma +\delta )r) . \end{aligned}$$

\(\square \)

Finally, we prove a perturbation result for the frequency function N.

Lemma 3.14

Let \(r>0\) and \(z \in \Omega \) with \(\vert z \vert \le \gamma r\) for \(\gamma >0\) small enough. Assume \(L_A r\) is small enough, \(0\in \Omega \), \(A(0) = I\), the ellipticity \(\Lambda _A\) of A(x) is small enough, and the point z and distance 4r are admissible. Then we have the following bound

$$\begin{aligned} N(0,r) \le O(\sqrt{L_A r}) + O(\sqrt{\gamma }) + N(z, 4r)\left( 1+O(\sqrt{L_A r})+O(\sqrt{\gamma }) \right) . \end{aligned}$$

If \(\gamma \) merely satisfies \(0<\gamma <(\Lambda _A+1)^{-1}\), we obtain

$$\begin{aligned} N(0,r) \le C + CN(z, 4r) \end{aligned}$$

for some constant \(C>0\).

Proof

Let \(\delta \in (0,1)\) to be chosen later. Using Lemma 3.11 we get the following upper and lower bounds

and

By Lemma 3.10, we have

$$\begin{aligned} 2N(0, r) (\log 2) \hbox {e}^{-C_N r} -c_H r \le \log \frac{H(0,2r)}{H(0,r)}. \end{aligned}$$

We aim to upper bound this quantity by something of the form \(\log (H(z, r_1) /H(z,r_2))\). To do this we will proceed as in Lemma 3.13.

Since \(A(0) = I\), we have \(\lambda _\text {max}(A(z)) = 1 + O(L_A\gamma r)\) and \(\lambda _\text {min} (A(z)) = 1 - O( L_A\gamma r)\) (maximum and minimum eigenvalues of A(z)). Let \({\tilde{S}}_z\) be the positive definite symmetric square root of A(z). From now on, we will denote \(\lambda _\text {max}({\tilde{S}}_z) =: \lambda _\text {max}\) and \(\lambda _\text {min}({\tilde{S}}_z) =: \lambda _\text {min}\), both depending on z.

We want to find an ellipsoidal annulus (with shape given by \({\tilde{S}}_z\)) centered at z that contains

$$\begin{aligned} {\mathcal {A}}^2_0 := {\mathcal {A}}(0, 2r, r(2+\delta )) \end{aligned}$$

and another one that is contained in

$$\begin{aligned} {\mathcal {A}}^1_0 := {\mathcal {A}}(0, r(1-\delta ), r). \end{aligned}$$

If we take an annulus \({\mathcal {A}}(0,r_1, r_2)\) and deform it by \({\tilde{S}}_z\), we get an “ellipsoidal annulus" \({\tilde{S}}_z {\mathcal {A}}(0,r_1, r_2)\) such that

$$\begin{aligned} {\mathcal {A}}(0,\lambda _{\text {max}}r_1, \lambda _{\text {min}}r_2) \subset {\tilde{S}}_z{\mathcal {A}}(0,r_1, r_2) \subset {\mathcal {A}}(0, \lambda _{\text {min}}r_1, \lambda _{\text {max}}r_2). \end{aligned}$$

Using this, we can choose the following annuli

$$\begin{aligned} {\mathcal {A}}^2_0 \subset \{z\} + {\tilde{S}}_z{\mathcal {A}}(0, \lambda _\text {max}^{-1}(2-\gamma )r, \lambda _\text {min}^{-1}(2+\delta +\gamma )r) =: \{z\} + {\tilde{S}}_z\mathcal {\mathcal {A}}^2_z \end{aligned}$$

and this other one (recall \(|z| \le \gamma r\))

$$\begin{aligned} {\mathcal {A}}^1_0 \supset \{z\} + {\tilde{S}}_z{\mathcal {A}}(0, \lambda _\text {min}^{-1} (1-\delta +\gamma )r, \lambda _\text {max}^{-1}(1-\gamma )r) =: \{z\} + {\tilde{S}}_z{\mathcal {A}}^1_z. \end{aligned}$$

For this last annulus to be well defined, we need

$$\begin{aligned} \lambda _\text {min}^{-1} (1-\delta +\gamma ) < \lambda _\text {max}^{-1}(1-\gamma ) \iff \delta > (1+\gamma ) - \left( \frac{\lambda _\text {max}}{\lambda _\text {min}} \right) ^{-1} (1 - \gamma ). \end{aligned}$$

We also require

$$\begin{aligned} \gamma \le \frac{1}{\frac{\lambda _\text {max}}{\lambda _\text {min}} + 1} < \frac{1}{2} \end{aligned}$$

so that \(\delta \) can satisfy \(\delta \le 1\).

Now we can proceed in the exact same way as in Lemma 3.13 to get

$$\begin{aligned} H(0,2r) \le (1+O({L_A r (1+\delta )})) \frac{\vert {\mathcal {A}}_z^2 \vert }{\vert {\mathcal {A}}_0^2 \vert } H(z, \lambda _{\text {min}}^{-1}(2+\gamma +\delta )r). \end{aligned}$$

In an analogous way, we can lower bound

$$\begin{aligned} H(0,r) \ge (1+O({L_A r (1+\delta )})) \frac{\vert {\mathcal {A}}_z^1 \vert }{\vert {\mathcal {A}}_0^1 \vert } H(z, \lambda _\text {min}^{-1}(1-\delta +\gamma )r). \end{aligned}$$

Putting both expressions together

$$\begin{aligned} \begin{aligned} \log \left( \frac{H(0,2r)}{H(0,r)} \right)&\le (1+O(L_A r(1+\delta ))) +\log \left( \frac{|{\mathcal {A}}_z^2| |{\mathcal {A}}_0^1| }{|{\mathcal {A}}_z^1| |{\mathcal {A}}_0^2|} \right) \\&\quad + \log \left( \frac{H(z, \lambda _{\text {min}}^{-1}(2+\gamma +\delta )r)}{ H (z, \lambda _\text {min}^{-1} (1-\delta +\gamma )r)} \right) . \end{aligned} \end{aligned}$$
(3.3)

Using Lemma 3.10 again, we can upper bound \(\log \frac{H(z,r_1) }{ H(z, r_2)}\) in terms of N as

$$\begin{aligned} \log \left( \frac{ H(z, \lambda _{\text {min}}^{-1}(2+\gamma +\delta )r)}{ H (z, \lambda _\text {min}^{-1} (1-\delta +\gamma )r)} \right) \le ~&2 N(z, \lambda _{\text {min}}^{-1}(2+\gamma +\delta )r) \log \left( \frac{2+\gamma +\delta }{1-\delta +\gamma }\right) \nonumber \\&(1+O(L_A r (1+\delta ))) + O(L_A r (1+\delta )). \end{aligned}$$
(3.4)

Now we need to choose \(\delta \). Remember that \(\delta \) has to satisfy

$$\begin{aligned} 1> \delta > (1+\gamma ) - \left( \frac{\lambda _\text {min}}{\lambda _\text {max}} \right) (1 - \gamma ) = 2 \gamma + O(L_A r) (1 - \gamma ). \end{aligned}$$
(3.5)

We will choose \(\delta \) equal to the geometric mean of the left hand side and the right hand side of inequality (3.5), that is

$$\begin{aligned} \delta = \sqrt{(1+\gamma ) - \left( \frac{\lambda _\text {min}}{\lambda _\text {max}} \right) (1 - \gamma )}. \end{aligned}$$

On the other hand, \(\gamma \) has to satisfy

$$\begin{aligned} 0< \gamma < \frac{1}{\frac{\lambda _\text {max}}{\lambda _\text {min}} + 1} = \frac{1}{2+O(L_A r)} = \frac{1}{2} - O(L_A r). \end{aligned}$$

Notation: From now on, for this proof, we will write \(1 - \epsilon := \frac{\lambda _\text {min}}{\lambda _\text {max}}\). Thus \(\epsilon = O(L_A r)\).

Notice that

$$\begin{aligned} \sqrt{\gamma + \epsilon }\le \delta = \sqrt{2\gamma + \epsilon - \epsilon \gamma } \le \sqrt{2\gamma + \epsilon } \le O(\sqrt{\gamma }) + O(\sqrt{L_A r}) \end{aligned}$$

for \(\epsilon \) small enough (\(L_A r\) small enough). Now let’s bound every term that has appeared before on Equations (3.3) and (3.4). First we bound

$$\begin{aligned}&\log \left( \frac{2+\gamma + \delta }{1 - \delta +\gamma } \right) = \log \left( {\frac{2+\sqrt{ \left( 2-\epsilon \right) \gamma + \epsilon }+\gamma }{1-\sqrt{ \left( 2-\epsilon \right) \gamma +\epsilon } +\gamma }} \right) \le \log \left( {\frac{2+\sqrt{ \left( 2-\epsilon \right) \gamma + \epsilon }}{1-\sqrt{ \left( 2-\epsilon \right) \gamma +\epsilon } }} \right) \\&\quad \le \log \left( \frac{2 +\sqrt{2\gamma + \epsilon }}{1 - \sqrt{2\gamma + \epsilon }}\right) = \log (2)+ O(\sqrt{\gamma +\epsilon }) \le \log (2) + O(\sqrt{\gamma }) + O(\sqrt{L_A r}). \end{aligned}$$

To bound

$$\begin{aligned} \log \left( \frac{|{\mathcal {A}}_0^1| |{\mathcal {A}}_z^2|}{|{\mathcal {A}}_0^2||{\mathcal {A}}_z^1|} \right) = \log \left( \frac{(1-(1-\delta )^d) ((\lambda _\text {min}^{-1}(2+\delta +\gamma ))^d-(\lambda _\text {max}^{-1}(2-\gamma ))^d)}{((2+\delta )^d-2^d) ((\lambda _\text {max}^{-1}(1-\gamma ))^d-(\lambda _\text {min}^{-1}(1-\delta +\gamma ))^d)} \right) \end{aligned}$$

we separate it in two terms,

$$\begin{aligned} \log \boxed {A} = \log \left( \frac{1-(1-\delta )^d}{((1-\epsilon )(1-\gamma ))^d-(1-\delta +\gamma )^d} \right) \end{aligned}$$

and

$$\begin{aligned} \log \boxed {B} = \log \left( \frac{(2+\delta +\gamma )^d-((1-\epsilon )(2-\gamma ))^d}{(2+\delta )^d-2^d} \right) . \end{aligned}$$

Let’s write the first order expansion of the terms in \(\delta \):

  • \((1-\delta )^d = 1 - d\delta + O(\delta ^2)\)

  • \((1-\epsilon )^d = 1 -O(L_A r)\)

  • \((1-\gamma )^d \ge 1 -O(\delta ^2)\)

  • \((1-\delta +\gamma )^d =(1-\delta )^d + O(\gamma ) = 1-d\delta + O(\delta ^2) \)

Now we can use this in the first term

$$\begin{aligned} \boxed {A}&= \frac{ d \delta + O(\delta ^2)}{(1-O(L_A r)) (1 - O(\gamma )) - (1-d\delta + O(\delta ^2))} \\&\le \frac{ d \delta + O(\delta ^2)}{(1-O(L_A r)) (1 - O(\delta ^2)) - (1-d\delta + O(\delta ^2))} \\&= \frac{d\delta + O(\delta ^2)}{d\delta -O(L_A r) - O(\delta ^2)} \\&= 1 + O(L_A r/\delta ) + O(\delta ) \\&\le 1 + O(\sqrt{L_A r}) + O(\sqrt{\gamma }). \end{aligned}$$

As for the other term, we proceed similarly

$$\begin{aligned} \boxed {B}&= \frac{(2+\delta )^d+O(\gamma )-(1-O(L_A r))(2^d-O(\gamma ))}{d2^{d-1}\delta + O(\delta ^2)}\\&= \frac{d2^{d-1}\delta + O(\delta ^2) +O(\gamma ) +O(L_A r)}{d2^{d-1}\delta + O(\delta ^2)}\\&= 1 + O(\delta ) + O(\gamma /\delta ) + O(L_A r/\delta ) \\&\le 1 + O(\sqrt{L_A r}) + O(\sqrt{\gamma }). \end{aligned}$$

Using all the bounds obtained in the last paragraphs together with Eqs. (3.3) and (3.4), we get

$$\begin{aligned} N(0,r) \le O(\sqrt{L_A r}) + O(\sqrt{\gamma }) + {\tilde{N}}(z, \lambda _{\text {min}}^{-1}(2+\gamma +\delta )r)\left( 1+O(\sqrt{L_A r})+O(\sqrt{\gamma }) \right) \end{aligned}$$

for \(L_A r\) and \(\gamma \) small enough.

Finally, we can bound

$$\begin{aligned} \lambda _{\text {min}}^{-1}(2+\gamma +\delta )r \le 4r \end{aligned}$$

and use that \(\hbox {e}^{C_N r}N(r)\) is increasing to get a simpler expression.

Remark 3.15

To prove the second part of the lemma (\(\gamma \) not necessarily small), we just need to choose \(\delta \) as the arithmetic mean of the left hand side and the right hand side of inequality (3.5). The rest of the proof is straightforward.

\(\square \)

4 Behavior of the frequency function on cubes near the boundary

The aim of this section is to prove the first technical lemma concerning the behavior of N near the boundary. For an analogous proof in the harmonic case, see Section 3 of [33] or Sections 4.1 and 4.2 of [28].

4.1 Whitney cube structure on \(\Omega \)

We will consider the same Whitney cube structure in \(\Omega \) as [33].

Let \(H_0\) be the horizontal hyperplane through the origin, and \(B_0\) be a ball centered in \(\Sigma \) such that \(M B_0 \cap \partial \Omega \subset \Sigma \) for some very large M. We also assume that \(MB_0 \cap \partial \Omega \) is a Lipschitz graph with slope \(\tau \) small enough with respect to \(H_0\).

We consider the following Whitney decomposition of \(\Omega \): a family \({\mathcal {W}}\) of dyadic cubes in \({\mathbb {R}}^d\) with disjoint interiors and constants \(W>20\) and \(D_0 \ge 1\) such that

  1. (1)

    \(\bigcup _{Q\in {\mathcal {W}}} Q = \Omega \),

  2. (2)

    \(10Q \subset \Omega \), \(\forall Q \in {\mathcal {W}}\),

  3. (3)

    \(WQ \cap \partial \Omega \ne \varnothing \), \(\forall Q \in {\mathcal {W}}\),

  4. (4)

    there are at most \(D_0\) cubes \(Q' \in {\mathcal {W}}\) such that \(10Q \cap 10Q' \ne \varnothing \), \(\forall Q \in {\mathcal {W}}\). Further, for such cubes \(Q'\) we have \(\frac{1}{2} \ell (Q') \le \ell (Q) \le 2 \ell (Q')\).

We will denote by \(\ell (Q)\) the side length of Q and by \(x_Q\) the center of the cube Q. From these properties it is clear that \({\text {dist}}(Q,\partial \Omega ) \approx \ell (Q)\). Also we consider the cubes small enough so that \(\text {diam}(Q) < \frac{1}{20} {\text {dist}}(Q, \partial \Omega )\).

Now we will introduce a “tree" structure of parents, children and generations to this Whitney cube decomposition.

Let \(\Pi \) denote the orthogonal projection on \(H_0\) and choose \(R_0 \in {\mathcal {W}}\) such that \(R_0 \subset \frac{M}{2} B_0\). It will be the root of the tree and we define \({\mathcal {D}}^0_{\mathcal {W}} (R_0) = \{R_0\}\) (that is the set of cubes of generation 0 of the rooted tree). To characterize the generations \({\mathcal {D}}^k_{\mathcal {W}}(R_0)\) for \(k\ge 1\), we define first

$$\begin{aligned} J(R_0) = \{\Pi (Q) : Q \in {\mathcal {W}} \text { such that } \Pi (Q) \subset \Pi (R_0) \text { and } Q \text { is {below} } R_0\}. \end{aligned}$$

We have that \(J(R_0)\) is a family of \(d-1\) dimensional dyadic cubes in \(H_0\), all of them contained in \(\Pi (R_0)\). Let \(J_k(R_0) \subset J(R_0)\) be the subfamily of \((d-1)\)-dimensional dyadic cubes in \(H_0\) with side length equal to \(2^{-k} \ell (R_0)\). To each \(Q' \in J_k(R_0)\) we assign some \(Q\in {\mathcal {W}}\) such that \(\Pi (Q) = Q'\) and such that Q is below \(R_0\) (notice that there may be more than one choice for Q but the choice is irrelevant), see [33, Lemma B.2], and we write \(s(Q') = Q\). Then we define

$$\begin{aligned} {\mathcal {D}}^k_{\mathcal {W}}(R_0) := \{s(Q') : Q' \in J_k(R_0)\} \end{aligned}$$

and

$$\begin{aligned} {\mathcal {D}}_{\mathcal {W}} (R_0) = \bigcup _{k \ge 0} {\mathcal {D}}^k_{\mathcal {W}}(R_0). \end{aligned}$$

Finally, for each \(R \in \mathcal {D}_{\mathcal {W}}^{k}\left( R_{0}\right) \) and \(j \ge 1\), we denote

$$\begin{aligned} \mathcal {D}_{\mathcal {W}}^{j}(R)=\left\{ Q \in \mathcal {D}_{\mathcal {W}}^{k+j}\left( R_{0}\right) : \Pi (Q) \subset \Pi (R)\right\} . \end{aligned}$$

By the properties of the Whitney cubes, we can observe that

$$\begin{aligned} Q \in \mathcal {D}_{\mathcal {W}}(R_{0}) \Rightarrow {\text {dist}}(Q, \Sigma )={\text {dist}}(Q, \partial \Omega ) \approx \ell (Q). \end{aligned}$$

Further, for any \(Q \in {\mathcal {W}}\), we denote its center by \(x_Q\), its associated cylinder by

$$\begin{aligned} {\mathcal {C}}(Q) := \Pi ^{-1}(\Pi (Q)), \end{aligned}$$

and the \((d-1)\)-dimensional Lebesgue measure on the hyperplane \(H_{0}\) by \(m_{d-1}\). In Appendix B of [33] one can find more details about the construction of this Whitney cube structure and its projections.

4.2 Lemma on the behavior of the frequency in the Whitney tree

Now we can present the first main lemma required in the proofs of Theorems 1.1 and 1.5. This lemma controls probabilistically the behavior of the frequency function in the tree of Whitney cubes defined in the last section. See [33, Lemma 3.1] for a version of this lemma for harmonic functions. Our proof is very similar. The reader only needs to consider that the properties of the frequency function for elliptic PDEs are slightly worse than those of the frequency function for harmonic functions, and that A(x) is a perturbation of the identity matrix. Also this Lemma should be compared with the (interior) Hyperplane lemma of [24] and [28, Lemma 7]. Note that, in what follows, we refer to the frequency function N of a solution of \({\text {div}}(A\nabla u)=0\) in \(\Omega \) as in the statement of Theorem 1.1.

Lemma 4.1

Let \(N_0 > 1\) be big enough. There exists some absolute constant \(\delta _0 > 0\) such that for all \(S \gg 1\) big enough the following holds, assuming also the Lipschitz constant \(\tau \) of \(\Sigma \) is small enough. Let R be a cube in \({\mathcal {D}}_\mathcal {W}(R_0)\) with \(\ell (R)\) small enough depending on S and \(L_A\) that satisfies \(N(x_R, S \ell (R)) \ge N_0\). Then, there exists some positive integer \(K = K(S)\) big enough such that if we let

$$\begin{aligned} \mathcal {G}_{K}(R)=\left\{ Q \in \mathcal {D}_{\mathcal {W}}^{K}(R): N(x_{Q}, S \ell (Q)) \le \frac{1}{2} N(x_{R}, S \ell (R))\right\} \end{aligned}$$

then:

  1. (1)

    \(m_{d-1}\left( \bigcup _{Q \in \mathcal {G}_{K}(R)} \Pi (Q)\right) \ge \delta _{0} m_{d-1}(\Pi (R))\),

  2. (2)

    for \(Q \in {\mathcal {D}}_\mathcal {W}^K(R)\), it holds

    $$\begin{aligned} N(x_Q, S\ell (Q)) \le (1+CS^{-1/2}) N(x_R, S\ell (R)) . \end{aligned}$$

    Note that (2) does not require \(N(x_R, S\ell (R))\ge N_0\).

It is important that \(\delta _0\) does not depend on S. Other constants such as M, K, and the upper bound on \(\tau \) do depend on S. Finally, \(N_0\) only depends on the dimension d.

Remark 4.2

Fix \(S,T>0\) and \(R \in {\mathcal {D}}_{{\mathcal {W}}}(R_0)\) with \(\ell (R)\) small enough depending on \(L_A\) and T. If \(x\in \Omega \) satisfies

$$\begin{aligned} {\text {dist}}(x,R) \le T \ell (R) \quad \text { and }\quad {\text {dist}}(x, \partial \Omega ) \ge T^{-1} \ell (R), \end{aligned}$$

then x and \(S \ell (R)\) are admissible, assuming \(M \gg T, M \gg S\), and that \(\tau \) is small enough. The proof is analogous to the proof of [33, Remark 3.3].

An important tool for the proof of the Lemma 4.1 is the following quantitative Cauchy uniqueness theorem.

Theorem 4.3

(Quantitative Cauchy uniqueness) Let u be a solution of \({\text {div}}(A(x)\nabla u(x))=0\) in the half ball

$$\begin{aligned} B_{+}=\left\{ y=\left( y^{\prime }, y^{\prime \prime }\right) \in \mathbb {R}^{d-1} \times \mathbb {R} \,|\, \left| y^{\prime }\right| ^{2}+|y^{\prime \prime }|^2<1,~ y^{\prime \prime }>0\right\} \end{aligned}$$

and suppose u is \(C^1\) smooth up to the boundary and A(x) is as discussed in Sect. 2.1. Let

$$\begin{aligned} \Gamma := \{ x \in {\mathbb {R}}^d \,|\, x_d = 0,~ \vert x \vert \le 3/4\} \end{aligned}$$

Suppose that \(\Vert u \Vert _{L^2(B^+)} \le 1\) and \( \Vert u \Vert _{W^{1,\infty }(\Gamma )} \le \epsilon \) for some \(\epsilon \in (0,1)\). Then

$$\begin{aligned} \sup _{B((0, \ldots , 0, 1/2) ,1/4)} \vert u\vert \le C \epsilon ^\alpha ~~\text { and } ~~\sup _{\frac{1}{4} B_+} |u| \le C' \epsilon ^{\alpha '} \end{aligned}$$

where \(C, C', \alpha ,\) and \(\alpha '\) are positive constants depending only on the ellipticity and the Lipschitz constant of the matrix A(x) and the dimension d.

This result is proved in great generality in [5, Theorem 1.7]. It will also be useful for the proof of Lemma 5.1. Before starting the proof of Lemma 4.1, we note that we will require both \(\Lambda _A-1\) and \(L_A\) very small in what follows (see again Remark 2.3 to see why we can do so).

Proof of Lemma 4.1

Let \(S\gg 1\) and then choose \(R \in {\mathcal {D}}_{\mathcal {W}}(R_0)\) with \(\ell (R)\) small enough depending on S and \(L_A\). For some \(j \gg 1\) independent of S that will be fixed below, consider the hyperplane L parallel to \(H_0\) (and above \(H_0\)) such that

$$\begin{aligned} {\text {dist}}(L, \Sigma \cap {\mathcal {C}}(R)) = 2^{-j}\ell (R) . \end{aligned}$$

From now on, we will denote by J the family of cubes from \({\mathcal {W}}\) that intersect \(L\cap {\mathcal {C}}(\frac{1}{2} R)\). By our construction of the Whitney cubes, we have \(\ell (Q) \approx 2^{-j}\ell (R)\) and \(\Pi (Q) \subset \Pi (R)\) for all \(Q\in J\). Notice that if \(\tau \) is small enough (depeding on j), then

$$\begin{aligned} {\text {dist}}(x, \Sigma \cap {\mathcal {C}}(10R)) \approx 2^{-j} \ell (R) \quad \text {for } x\in L \cap {\mathcal {C}}(10R) . \end{aligned}$$

Denote by Adm(2WQ) the set of points \(x\in \Omega \cap 2WQ\) such that the interval \((0, \text {diam}(25WQ))\) is admissible for x. We assume that the Lipschitz constant of the domain \(\tau \) is small enough so that \(3Q \subset \text {Adm}(2WQ)\) (using Remark 4.2). Then by Lemma 3.14, for Q small enough

$$\begin{aligned} \sup _{x \in \text {Adm}(2WQ)} N(x, {\text {diam}}(5 W Q)) \le C_{0} N(x_{Q}, {\text {diam}}(20 W Q))+C_{0} \end{aligned}$$
(4.1)

where \(C_0\) is an absolute constant. Note that \(|x-x_Q| \le {\text {diam}}(WQ) < \frac{1}{4} {\text {diam}}(5WQ)\) since \(x\in 2WQ\), hence it satisfies the conditions required by Lemma 3.14 (we use that the ellipticity constant is small enough).

Claim

There exists some \(Q \in J\) such that

$$\begin{aligned} N(x_Q, {\text {diam}}(20 W Q)) \le \frac{N(x_R, S\ell (R))}{4C_0} \end{aligned}$$
(4.2)

if j is big enough (but independent of S) and we assume that \(\tau _0\) is small enough depending on j, and also \(N_0\) is big enough.

Proof of the claim

From now on, we denote \(N = N(x_R, S\ell (R))\). Our aim is to prove the claim using Theorem 4.3 in a small half-ball centered at \(z_R\), the projection of \(x_R\) onto the hyperplane L. Set

$$\begin{aligned} B_+ := \{ x\in B(z_R, \ell (R)/4) \,|\, x_d > (z_R)_d \} \subset \Omega . \end{aligned}$$

Also, let \({\tilde{z}}_R := z_R + (0, \ldots , 0, \ell (R)/8) \in B_+\). Note that, rescaling \(B_+\), \({\tilde{z}}_R\) corresponds to the point \((0,\ldots , 0, 1/2)\) in the statement of Theorem 4.3.

We aim for a contradiction, so we assume that \( N(x_Q, \text {diam}(20WQ)) > N/(4C_0)\) for all \(Q \in J\), where \(N = N(x_R, S\ell (R))\). For each \(Q\in J\), we have

by standard properties of solutions of elliptic PDEs. Then, by Lemma 3.12, we obtain

where \(c_H\) is the constant from Lemma 3.10. Note that \(\hbox {e}^{c_H \text {diam}{(20WQ)}} = 1+O(L_A \ell (Q))\), omiting the dependence on \(\Lambda _A\) (which we may assume is very close to 1). Using Lemma 3.10 we obtain the following bound using the frequency function:

$$\begin{aligned}{} & {} H(x_Q, \text {diam}(20WQ))\\{} & {} \qquad \le H(x_Q, \ell (R)) \left( \frac{\text {diam}(20WQ)}{\ell (R)} \right) ^{2 N(x_Q, \text {diam}(20WQ))(1+O(L_A \ell (Q)))} (1+O(L_A \ell (Q))) . \end{aligned}$$

Note that for the previous step we need \(\tau \) small enough depending on j. At other points of the proof we will require \(\tau \) small enough but without further reference.

Now we estimate \(H(x_Q, \ell (R))\) as follows

where we have used Remark 3.9, and that for some fixed \(C_1>0\) we have that \(A(x_Q)^{1/2} {\mathcal {A}}(x_Q, \ell (R), 2\ell (R)) \subset {\mathcal {A}}({{\tilde{z}}_R})^{1/2}B({\tilde{z}}_R,C_1 \ell (R))\). Finally, using Lemma 3.11 we can bound

$$\begin{aligned} H(x_Q, \ell (R)) \lesssim (1+O(L_A \ell (R))) H({\tilde{z}}_R, C_1\ell (R)). \end{aligned}$$

Moreover, using again Lemma 3.10, we can further bound as follows

and recalling that \(B({\tilde{z}}_R, \ell (R)/8) \subset B_+\) even after considering the reescaling by \(A({\tilde{z}}_R)^{1/2}\), we obtain

Now, using that \(L_A \ell (R)\) is very small, we can bound all the terms \(O(L_A \ell (R))\) by 1, for example. Thus, summing up all the computations we have done, we can write

(4.3)

By Lemma 3.14, we have

$$\begin{aligned} N({\tilde{z}}_R, C_1 \ell (R)) \le C N (x_R, S\ell (R)) + C \le C'N \end{aligned}$$
(4.4)

for a suitable constant \(C>2C_1\) if S is large enough, and \(N_0\) too.

Recalling that we assumed for all \(Q \in J\) that \(N(x_Q, \text {diam}(20WQ)) > \frac{N}{4C_0}\), we get

for some positive constants \(C''\) and \(C'''\). We have used that \(\text {diam}(20 W Q) < \ell (R)\) by choosing j large enough.

Using interior estimates for solutions of elliptic PDEs

From the last two estimates we deduce that if j is big enough (depending on the absolute constants \(C''\) and \(C'''\)) and \(N_0\) (and thus also N) is big enough too, then there exists some \(c'>0\) such that

Since the cubes \(\frac{3}{2} Q\) with \(Q \in J\) cover the flat part of the boundary of \(B_+\), we can apply a rescaled version of Theorem 4.3 to \(B_+\) to get

(4.5)

for some \(\alpha > 0\). Observe that we can lower bound

$$\begin{aligned} \sup _{B({\tilde{z}}_R, \ell (R)/16)} \vert u \vert ^2 > rsim H({\tilde{z}}_R, \ell (R)/16) \end{aligned}$$

and upper bound

Using these bounds in (4.5) we obtain

$$\begin{aligned} H({\tilde{z}}_R, \ell (R)/16) \lesssim 2^{-jc'N\alpha } H({\tilde{z}}_R, \ell (R)). \end{aligned}$$

By Lemma 3.10, this implies

$$\begin{aligned} 2 N({\tilde{z}}_R, \ell (R))(\log 16) (1+O(L_A \ell (R))) + O(L_A \ell (R)) \ge \log \left( \frac{ H({\tilde{z}}_R, \ell (R))}{ H({\tilde{z}}_R, \ell (R)/16)} \right) > rsim c'jN\alpha \end{aligned}$$

for some fixed \(c'>0\). But for j big enough this contradicts the fact that \( N({\tilde{z}}_R, \ell (R)) \lesssim N\) by (4.4). Observe though that j “big enough" does not depend on the election of S. \(\square \)

Now we may introduce the set \({\mathcal {G}}_K(R)\). Fix \(Q_0 \in J\) such that (4.2) holds for \(Q_0\). Notice that, by (4.1)

$$\begin{aligned} \sup _{x \in \text {Adm}(2WQ_0)} N(x, {\text {diam}}(5 W Q_0)) \le C_{0} N(x_{Q_0}, {\text {diam}}(20W Q_0))+C_{0} \le \frac{N}{2} \cdot \left( \frac{10}{11} \right) ^2\nonumber \\ \end{aligned}$$
(4.6)

since \(N \ge N_0\) and we assume \(N_0\) big enough. The precise value of the constant \(\left( \frac{10}{11} \right) ^2\) is not important. Finally, we can define

$$\begin{aligned} {\mathcal {G}}_K(R) = \{Q \in {\mathcal {D}}_{{\mathcal {W}}}^{j+k}(R) : \Pi (Q) \subset \Pi (Q_0) \} \end{aligned}$$

with \(k = \lceil \log _2 S\rceil \). Thus, we have \({\mathcal {G}}_K(R)\subset {\mathcal {D}}^K_{\mathcal {W}}(R)\) with \(K = j+k\) and it holds \(\ell (Q) = 2^{-k}\ell (Q_0)\) for every \(Q \in {\mathcal {G}}_K(R)\).

The property (1) follows from (4.6). Indeed if \(P \in {\mathcal {G}}_K(R)\), then taking into account that \(x_P \in \text {Adm}(2WQ_0)\) for \(\tau \) small enough (depending on S) and using Proposition 3.8 we get

$$\begin{aligned} N(x_P, S\ell (P)) \le \frac{11}{10} N(x_P, \ell (Q_0)) \le \left( \frac{11}{10}\right) ^2 N(x_P, W \ell (Q_0)) \le \frac{N}{2} \end{aligned}$$

where we have bounded the terms \(1+O(L_A \ell (Q_0))\) by 11/10. Notice also that

$$\begin{aligned} m_{d-1}\left( \bigcup _{Q \in \mathcal {G}_{K}(R)} \Pi (Q)\right) = l\left( Q_{0}\right) ^{d-1} \approx \left( 2^{-j} \ell (R)\right) ^{d-1} \end{aligned}$$

and recall that j is independent of S. So (1) holds with \(\delta _0 \approx 2^{-j(d-1)}\).

The property (2) is a consequence of Lemma 3.14. Indeed for any \(P \in {\mathcal {D}}^K_{\mathcal {W}} (R)\), since \(\vert x_P - x_R \vert \lesssim \ell (R)\), taking \(\gamma \approx S^{-1}\) in the Lemma 3.14, we deduce

$$\begin{aligned} N(x_P, S\ell (P))&\le (1 + O(L_A S\ell (R))) N(x_P, S\ell (R)/3) \\&\le (1 + O(L_A S\ell (R))) \left[ O(\sqrt{L_A S \ell (R)}) + O (\sqrt{S^{-1/2}}) \right] \\&\quad +\, (1+O(L_A S \ell (R))) N(x_R, S \ell (R)) \left[ 1 + O(\sqrt{L_A S \ell (R)}) + O (\sqrt{S^{-1/2}})) \right] . \end{aligned}$$

Assuming that \(\ell (R) \lesssim S^{-2}\) and \(N_0\) large enough, we obtain

$$\begin{aligned} N(x_P, S \ell (P)) \le (1 + CS^{-1/2})N(x_R, S \ell (R)) \end{aligned}$$

for certain constant C. \(\square \)

5 Balls without zeros near the boundary

In this section we will prove the second main lemma concerning the behavior of N near the boundary. This lemma shows that if we have a ball near the boundary with bounded frequency, then we can find a smaller ball centered at the boundary where u does not change sign. The following lemma should be compared with [28, Lemma 8] that treats the harmonic case. Note that, in what follows, we refer to the frequency function N(xr) of a solution of \({\text {div}}(A\nabla u)=0\) in \(\Omega \) as in the statement of Theorem 1.1. Moreover, we consider \(\Omega \) with the Whitney structure defined in Sect. 4.1.

Lemma 5.1

For any \(N>0\) and \(S \gg 1\) large enough there exist positive constants \(\tau _0(N,S)\) and \(\rho (N,S)\) such that the following statement holds. Suppose the Lipschitz constant \(\tau \) of \(\Sigma \) is smaller than \(\tau _0\) and Q is a cube in \({\mathcal {D}}_{\mathcal {W}}(R)\) such that \(N(x_Q, S \ell (Q)) \le N\). Then there exists a ball B centered in \(\Sigma \cap {\mathcal {C}}(Q)\) with radius \(\rho \ell (Q)\) such that u does not vanish in \(B \cap \Omega \).

First, we will prove a “toy" version of this lemma on the half ball \(B_+\) for harmonic functions. The following lemma is essentially [28, Lemma 9] but formulated using the frequency function instead of the doubling index (a closely related quantity used in [28]).

Lemma 5.2

Let B be the unit ball in \({\mathbb {R}}^d\) and let \(B_+\) be the half ball,

$$\begin{aligned} B_{+}=\left\{ y=\left( y', y''\right) \in \mathbb {R}^{d-1} \times \mathbb {R}\, | \,|y'|^{2}+|y''|^2<1, y''>0\right\} . \end{aligned}$$

Let u be a function harmonic in \(B_{+}\) such that \(u \in C(\overline{B_{+}})\), \(u=0\) on \(\Gamma := \partial {B}_{+} \cap \left\{ y^{\prime \prime }=0\right\} \), and

$$\begin{aligned} \sup _{\frac{1}{4} B_{+}}|u|=1. \end{aligned}$$

For any \(N>0\) and \(0<r_0<1/16\), there exist \(\rho =\rho (N, r_0) >0 \) and \(c_{0}=c_{0}(N, r_0)>0\) such that if \(N(0,1/2) \le N\), then there is \(x^{\prime } \in \mathbb {R}^{d-1}\) with \(\left| x^{\prime }\right| < r_0\) such that

$$\begin{aligned} |u(y)| \ge c_{0} y^{\prime \prime }, \quad \text{ for } \text{ any } \quad y=(y^{\prime }, y^{\prime \prime }) \in B((x^{\prime }, 0), \rho ) \cap B_{+} . \end{aligned}$$

In particular, u does not vanish in \(B\left( \left( x^{\prime }, 0\right) , \rho \right) \cap B_{+}\).

The notation \(\frac{1}{n} B_+\) used in the previous statement stands for \(\{y \in {\mathbb {R}}^d \, |\, n y \in B_+ \}\).

Proof

Let \(B_-\) be the reflection of the half-ball \(B_+\) with respect to \(\Gamma =\{y''=0\}\cap \partial B_+\). Since u vanishes on \(\Gamma \), u can be extended to a harmonic function in B by the Schwarz reflection principle. We also denote this extension by u.

Using Cauchy estimates we can uniformly bound every partial derivative of u inside B(0, 1/8) obtaining

$$\begin{aligned} \sup _{x \in B(0,1/8)}\vert \nabla u(x) \vert \lesssim \sup _{B(0, 1/4)} \vert u \vert = 1. \end{aligned}$$

Let \(\delta := \max _{\begin{array}{c} x' \in {\mathbb {R}}^{d-1},\\ \vert x'\vert \le r_0 \end{array}} \vert \nabla u(x',0)\vert \). Then, Theorem 4.3 applied to \(r_0 B_+\) implies that

$$\begin{aligned} \sup _{B(0,r_0/4)}\vert u \vert \le C \delta ^\gamma \end{aligned}$$

for some positive C and \(\gamma \in (0,1)\). Then and by subharmonicity .

By the monotonicity of N in the harmonic case, we also have

We can conclude that

$$\begin{aligned} \log _{2/r_0} \frac{c}{C \delta ^{2\gamma }} \le N \implies \delta \ge c' \left( \frac{2}{r_0}\right) ^{-\frac{N}{2\gamma }}. \end{aligned}$$

Now, choose \(x_*' \in {\mathbb {R}}^{d-1}, \vert x_*'\vert \le r_0\) such that \(\vert \nabla u(x_*',0) \vert = \delta \). Clearly, at this point, \(\vert \nabla u(x_*',0) \vert = \vert \partial _d u(x_*',0) \vert \) (the derivative in the direction normal to \(\Gamma \)). Without loss of generality, assume that \(\partial _d u(x_*',0) = \delta \). Observe that the second derivatives of u are uniformly bounded in B(0, 1/8) using Cauchy estimates (as we have done before). Thus, we have

$$\begin{aligned} \partial _d u(y) > \delta /2 \quad \text{ when } {\text {dist}}(y,(x_*',0)) < \rho = \min \{c_0 \delta , r_0\} \end{aligned}$$

where \(c_0\) only depends on the bound on the second derivatives, and thus is an absolute constant. Using this, we finally get

$$\begin{aligned} u(y) \ge \frac{\delta }{2} y^{\prime \prime } \ge c'' \left( \frac{2}{r_0} \right) ^{-\frac{N}{2\gamma }} y^{\prime \prime }, \\ \end{aligned}$$

for \(y=\left( y^{\prime }, y^{\prime \prime }\right) \in B\left( \left( x_{*}^{\prime }, 0\right) , \rho \right) \cap B_+\). \(\square \)

Now we will prove an elliptic extension of the previous lemma. Unfortunately, the proof presents some complications since we do not have an adequate substitute to Schwarz’s reflection principle. To overcome this, we assume that our function u is a solution of \({\text {div}}(A(x)\nabla u)=0\) where A(x) is a small (Lipschitz) perturbation of the identity matrix, and we show that there is a harmonic function v very close to u in \(C^1\) norm for which the previous lemma holds. Then, we obtain that there is a smaller ball where u does not vanish either.

Lemma 5.3

Let u be a solution of \({\text {div}}(A\nabla u)=0\) in \(B_{+}\) such that \(u \in C(\overline{{B}_{+}})\), \(u=0\) on \(\Gamma := \partial {B}_{+} \cap \left\{ y^{\prime \prime }=0\right\} \), and

$$\begin{aligned} \sup _{\frac{1}{4} B_{+}}|u|=1 \end{aligned}$$

where \(\frac{1}{4} B_{+} = \left( \frac{1}{4} B\right) _+\). For any \(N>0\) and \(0<r_0<1/32\), there exist \(\rho =\rho (N, r_0) >0 \) and \(c_{0}=c_{0}(N, r_0)>0\) such that if \(N(0,1/2) \le N\), then there is \(x^{\prime } \in \mathbb {R}^{d-1}\) with \(\left| x^{\prime }\right| < r_0\) such that

$$\begin{aligned} |u(y)| \ge c_{0} y^{\prime \prime }, \quad \text{ for } \text{ any } \quad y=\left( y^{\prime }, y^{\prime \prime }\right) \in B\left( \left( x^{\prime }, 0\right) , \rho \right) \cap B_{+} \end{aligned}$$

assuming that \(L_A\) and \(\Lambda _A-1\) are small enough depending on N and \(r_0\) (where \(L_A\) and \(\Lambda _A\) are the Lipschitz and ellipticity constants of A(x), respectively). In particular, u does not have zeros in \(B\left( \left( x^{\prime }, 0\right) , \rho \right) \cap B_{+}\).

Proof

Let v be the harmonic extension of \(u|_{\partial (\frac{1}{2} B_+)}\) defined in \(\frac{1}{2}B_+\). We intend to use Lemma 5.2 to find a ball B such that \(|v(y',y'')| > rsim y''\) for \((y',y'')\in B\cap \Omega \). Afterwards, we will see that if \(L_A\) and \(\Lambda _A-1\) are small enough, then the difference \(v-u\) is arbitrarily small in \(W^{1,\infty }(B\cap \Omega )\) which will prove the lemma (for a smaller concentric ball).

First, we bound the frequency (associated to \(\Delta \)) of v as follows

using that v is the minimizer of the Dirichlet energy for the boundary condition \(u|_{\partial (B_+/2)}\). We also have that

obtaining an upper bound for \(N^v(0,1/2)\). Analogously, we may also obtain a lower bound for \(N^v(0,1/2)\) in terms of \(N^u(0,1/2)\) using that u minimizes a weighted Dirichlet energy.

Consider the function \(h = v-u\) defined in \(\frac{1}{2}B_+\). Note that h is a solution of

$$\begin{aligned} {\left\{ \begin{array}{ll} {\text {div}}(A\nabla h)= {\text {div}}((A-I)\nabla v), &{}\text {in } \frac{1}{2}B_+,\\ h= 0, &{}\text {on } \partial \frac{1}{2} B_+. \end{array}\right. } \end{aligned}$$

We aim to bound h(x) and \(\nabla h(x)\) in \(\frac{1}{16} B_+\) in terms of \(N, L_A\), and \(\Lambda _A\). Using the Green’s function \(G_A(x,y)\) for the elliptic operator \({\text {div}}(A(x)\nabla \cdot )\) in \(\frac{1}{2}B_+\), we can represent h(x) as

for \(x \in B_+/16\). We split this integral in two parts and take absolute values:

In both integrals we bound \(|A-I|\) by \(\Lambda _A-1\). Also, in the first integral, we are going to bound \(|\nabla v(y)|\lesssim 2^{cN}\) for some \(c>0\) using Cauchy estimates. To this end, we consider v extended to \(\frac{1}{2} B\) using Schwarz reflection principle, and then, for \(y \in \frac{1}{8} B\), we obtain

where we have also used \(H^u(0,1/4) \lesssim \sup _{\frac{1}{4} B_+} |u|^2 = 1\). Remember that , as v is harmonic.

Then, using that \(\nabla _y G_A(x,\cdot )\) has weak \(L^{\frac{d}{d-1}}\) norm bounded by a constant depending only on \(\Lambda _A\) and d (see [17, estimate (1.6)] together with the symmetry of A), we get

Thus, we can bound the first integral by

For the other integral, we use Cauchy–Schwarz to obtain

Invoking [17, Theorem 3.3], we have that \(|\nabla _y G_A(x,y)|\le C |x-y|^{1-d} \lesssim 1\) for \(x \in \frac{1}{16}B_+\) and \(y \in \frac{1}{2} B_+ \backslash \frac{1}{8} B_+\), which allows us to bound \({\boxed {A}.}\) We estimate \({\boxed {B}}\) as follows:

where we have used that \(H^v(0,1/2) \lesssim 2^{cN}\), as shown before.

Summing up all the previous estimates, we have obtained \(|h(x)| \lesssim C(N, \Lambda _A)(\Lambda _A -1)\) for \(x\in \frac{1}{16}B_+\). Now, [16, Corollary 8.36] gives us

$$\begin{aligned} \Vert h \Vert _{C^{1,\alpha }({\frac{1}{32}B_{+}})} \lesssim \Vert h \Vert _{L^\infty (\frac{1}{16} B_+)} + \Vert (A-I)\nabla v\Vert _{C^{0,\alpha }(\frac{1}{16} B_+)} \end{aligned}$$

for some \(\alpha \in (0,1)\). Using the product rule for derivatives, we get

$$\begin{aligned} \Vert (A-I)\nabla v\Vert _{C^{0,\alpha }(\frac{1}{16} B_+)} \lesssim \Vert (A-I)\nabla v\Vert _{C^{0,1}(\frac{1}{16} B_+)} \lesssim L_A \Vert \nabla v \Vert _{L^\infty (\frac{1}{16} B_+)} + (\Lambda _A-1) \Vert D^2 v \Vert _{L^\infty (\frac{1}{16} B_+)}. \end{aligned}$$

Finally, using interior Cauchy estimates to estimate \(\Vert D^2 v \Vert _{L^\infty (\frac{1}{16} B_+)}\) and \(\Vert \nabla v \Vert _{L^\infty (\frac{1}{16} B_+)}\) in terms of N, we get

$$\begin{aligned} |\nabla h(x)| \le C(N) \left( L_A + (\Lambda _A-1) \right) , \quad x \in \frac{1}{32}B_+ . \end{aligned}$$

To end the proof, we apply Lemma 5.2 to v to get a ball where

$$\begin{aligned} |v(y)| \ge c_{0} y^{\prime \prime }, \quad \text{ for } \text{ any } \quad y=\left( y^{\prime }, y^{\prime \prime }\right) \in B\left( \left( x^{\prime }, 0\right) , \rho \right) \cap B_{+} \end{aligned}$$

and we make \(L_A\) and \(\Lambda _A-1\) small so that \(\partial _d h(x) \le c_0/2\) in \(\frac{1}{32}B_+\). This implies \(|h(y',y'')| \le \frac{c_0}{2} y''\) and, since \(|u| \ge |v|-|h|\), it finishes the proof. \(\square \)

We need to state a last lemma before proving Lemma 5.1.

Lemma 5.4

Let \(\Sigma \subset {\mathbb {R}}^d\) be a Lipschitz graph with respect to the hyperplane \(H_0\) with Lipschitz constant \(\tau <1/2\), assume that \(0\in \Sigma \), and let u be a solution of \({\text {div}}(A\nabla u)=0\) in the domain \(\Omega = \{x + r e_d \,|\, x \in \Sigma \cap B(0,1), r \in (0,1)\}\). Then, there exist positive constants M and \(\delta \) depending on the Lipschitz constant \(L_A\) and the ellipticity constant \(\Lambda _A\) of A(x) such that the following statement holds. If \(u \ge -1\) in \(\Omega \cap B(0,1)\), \(u\equiv 0\) on \(\Sigma \) and \(u \ge M\) on \(\{x + r e_d \,|\, x \in \Sigma \cap B(0,1), r \in (\delta ,1)\}\cap B(0,1)\), then \(u\ge 0\) in \(\Omega \cap B(0,1/2)\).

The proof of this lemma is Step 1 of the proof of [11, Theorem 1.1]. For a simpler proof in the harmonic case (in Lipschitz domains with small Lipschitz constant), see Appendix B in [13].

In the following proof, we will assume again that \(L_A\) and \(\Lambda _A-1\) are very small (see Remark 2.3).

Proof of Lemma 5.1

Let \(S \gg 1\) and Q be a cube of our Whitney cube structure such that \(x_Q\) (the center of Q) and \(S \ell (Q)\) are admissible and \(N(x_Q, S \ell (Q)) \le N\). Note that, to attain this, we need the Lipschitz constant of the domain \(\tau \) small enough depending on S. Further, we assume that \(S \ell (Q) = 8\) by rescaling the domain and the Whitney cube structure. This rescaling changes the Lipschitz constant \(L_A\) of the matrix A(x) corresponding to the elliptic operator. But if the cube Q is small enough, the rescaling improves it, that is, makes \(L_A\) smaller.

Let \({\tilde{x}}\) be the projection (in the direction \(e_d\)) of x on \(\Sigma \). Then, if S is big enough, we have

$$\begin{aligned} \log \frac{H({\tilde{x}},S\ell (Q)/2^{k})}{H({\tilde{x}},S\ell (Q)/2^{k+1})}\le & {} \log c + \log \frac{H(x_Q,S\ell (Q)/2^{k-1})}{H(x_Q,S\ell (Q)/2^{k+2})} \nonumber \\\le & {} \log c + N c' , ~ \forall k\in \{1,\ldots ,5\}. \end{aligned}$$
(5.1)

by Lemmas 3.10 and 3.13 (since we do not assume \(A(x_Q)=I\) or \(A({\tilde{x}})=I\), we use first Remark 3.9). We need S large enough so that \(B({\tilde{x}}, \Lambda _A S\ell (Q)/2^k) \subset B(x_Q, S\ell (Q)/2^{k-1})\) and \(B({\tilde{x}}, S\ell (Q)/2^{k+1}) \supset B(x_Q, \Lambda _A S\ell (Q)/2^{k+2})\) (we are using that \(\Lambda _A\) is very close to 1) for \(k=1,\ldots ,5\). From now on, S is fixed.

We also fix the following normalization for u:

$$\begin{aligned} \sup _{B({\tilde{x}},3)\cap \Omega } \vert u \vert = 1 \end{aligned}$$
(5.2)

(remember that \(S\ell (Q) = 8\)).

Let \(x_1 = {\tilde{x}} - 3 \tau e_d\). Observe that

$$\begin{aligned} \Gamma _0 = \{ x = (x', x'') \in B(x_1, 2) : x'' = x_1'' \} \end{aligned}$$

doesn’t intersect \({\overline{\Omega }}\). Also let \(B_1:=B(x_1, 1), B_2 :=B(x_1, 2)\) and \(B_{k,+}\) the upper half of \(B_k\), \(k=1,2\) (the half of \(B_k\) that intersects \(\Omega \)), see Fig. 1.

Fig. 1
figure 1

The domain \(\Omega \), the Lipschitz graph \(\Sigma \), and the half ball \(B_{2,+}\)

Let \(g_0\) be the solution of \({\text {div}}(A\nabla g_0)=0\) on \(B_{2,+}\) such that \(g_0 \equiv 1\) on \(\partial B_{2,+}\backslash \Gamma _0\) and \(g_0 \equiv 0\) on \(\Gamma _0\). By the maximum principle \(g_0 \ge 0\) on \(B_{2,+}\) and \(g_0 \ge \vert u \vert \) on \(\Omega \cap B_2 \subset B_{2,+}\) because of the normalization (5.2) of u. Notice that, moreover, we have the bound

$$\begin{aligned} g_0(x) \le C_1(x''-x_1'') \end{aligned}$$

for \(x\in B_{1,+}\) which gives us a bound for \(\vert u \vert \) in \(\Omega \cap B_1\). In the case \(A \equiv I\), this follows from reflection and interior Cauchy estimates for \(\nabla u\). In the general case, we may use that \(g_0(x)\) is comparable to the Green function \(G_A(x, y)\) of the domain \(B_{2,+}\) (with pole \(y=(0,\ldots ,0,1.5)\) for example) by the boundary Harnack inequality inside \(B_{1,+}\). By [17, Theorem 3.3], since \(B_{2,+}\) satisfies an exterior sphere condition, we have that \(G(x,y) \lesssim {\text {dist}}(x,\partial B_{2,+}) |x-y|^{1-d} \approx {\text {dist}}(x,\partial B_{2,+})\). Further, for \(x \in B_{1,+}\) we have that \({\text {dist}}(x,\partial B_{2,+}) = x'' - x_1''\) which gives us the desired bound.

Let g be the solution of \({\text {div}}(A\nabla g)=0\) in \(B_{1,+}\) with Dirichlet boundary conditions \(g \equiv u\) on \(\partial B_{1,+} \cap \Omega \) and \(g \equiv 0\) on \(\partial B_{1,+} \backslash \Omega \). Since \(|u| \le g_0\) in \(B_{2,+}\cap \Omega \), we have \(\vert g \vert \le g_0 \le C_1(x''-x_1'')\). Also,

$$\begin{aligned} |g-u| = {\left\{ \begin{array}{ll} 0, \quad &{}\text {on } \Omega \cap \partial B_{1,+}, \\ |g| \le 4C_1 \tau , \quad &{}\text {on } \partial \Omega \cap B_{1,+}, \end{array}\right. } \end{aligned}$$
(5.3)

because of the bound of \(|g|\le g_0\le C_1(x''-x_1'')\).

By (5.1), Remark 3.9, Lemma 3.12, Lemma 3.11, Proposition 3.2, and (5.2), we have

where \(x_{\sup {}}\) is a point in \(\partial B({\tilde{x}},3)\) where \(|u(x_{\sup {}})|=1\). Assuming that \(\tau \) is small enough, we have \(B({\tilde{x}}, \frac{1}{8}) \cap \Omega \subset \frac{1}{4} B_{1,+}\). Using (5.3) and Lemma 3.13, we get

If we assume that \(\tau \) (depending on N) is small enough, we conclude that

$$\begin{aligned} \Vert g \Vert _{L^2\left( \partial \left( \frac{1}{4} B_{1,+}\right) \right) } \ge c_1 \hbox {e}^{-c'N/2}. \end{aligned}$$
(5.4)

Now let’s estimate the doubling of \(H^g(x_1,r)\) for g by using (5.2) and (5.4):

This gives us an upper bound for \(N^g(x_1,1/4)\), the frequency for g at \(x_1\). Also note that (5.4) implies

$$\begin{aligned} \sup _{\frac{1}{4} B_{1,+}} \vert g \vert \ge c \hbox {e}^{-c' N/2}. \end{aligned}$$

Then, by Lemma 5.3, there exists \(x_* \in \Gamma _0 \cap B_{1/S}\), \(c_2 = c_2(C(N+1), S) >0\), and \(\rho = \rho (C(N+1), S)\) such that

$$\begin{aligned} |g(x)| \ge c_{2}\left( x^{\prime \prime }-x_{1}^{\prime \prime }\right) \text{ for } x=\left( x^{\prime }, x^{\prime \prime }\right) \in B\left( x_{*}, \rho \right) \cap B_{1,+} . \end{aligned}$$

We may assume that \(g>0\) in \(B\left( x_{*}, \rho \right) \cap B_{1,+}\), otherwise we consider \(-u\) and \(-g\) in place of u and g. From (5.3), we obtain

$$\begin{aligned} u(x) \ge g(x)-4 C_1 \tau \ge c_{2}\left( x^{\prime \prime }-x_{1}^{\prime \prime }\right) -4 C_1 \tau \quad \text{ in } \quad B\left( x_{*}, \rho \right) \cap \Omega . \end{aligned}$$
(5.5)

Note that \(\rho \) does not depend on \(\tau \) and for \(\tau \) small enough we have \(B\left( x_{*}, \frac{\rho }{4}\right) \cap \partial \Omega \ne \varnothing .\)

Our goal is to show that \(u > 0\) on \(B(x_*, \frac{\rho }{2}) \cap \Omega \) and we will use Lemma 5.4 to this end (from now on, constants \(\delta \) and M come from the statement of Lemma 5.4). Restrict \(\tau \) to be small enough so that \(u>0\) in \(B(x_*, \rho ) \cap \Omega \cap \{ (x', x'') | x'' > x''_* + \delta \rho \}\), which we can do thanks to (5.5). Now, we multiply the function u by a very large constant K so that \(Ku \ge M\) in the same set \(B(x_*, \rho ) \cap \Omega \cap \{ (x', x'') | x'' > x''_* + \delta \rho \}\). Finally, we make \(\tau \) even smaller so that \(Ku \ge -1\) in \(B(x_*, \rho ) \cap \Omega \), thanks again to (5.5). Now, by a rescaled version of Lemma 5.4 to \(B(x_*,\rho )\cap \Omega \), the function Ku restricted to \(B(x_*, \rho /2)\cap \Omega \) is positive, which implies that u is positive too and ends the proof. \(\square \)

6 Proof of Theorems 1.1 and 1.5

We will combine Lemmas 4.1 and 5.1 to prove Theorems 1.1 and 1.5.

Note that, in the present section, we refer to the frequency function N of a solution of \({\text {div}}(A\nabla u)=0\) in \(\Omega \) as in the statement of Theorem 1.1. Without further mention, we will use that the constants \(L_A\) and \(\Lambda _A -1\) from the matrix A(x) are very small thanks to Remark 2.3. Moreover, we consider \(\Omega \) with the Whitney structure defined in Sect. 4.1.

First, we give a corollary to Lemma 5.1 in a language closer to that of Lemma 4.1.

Corollary 6.1

For any \(N>0\) and \(S \gg 1\) large enough there exist positive constants \(\tau _0(N,S)\) and K(NS) such that the following statement holds. Suppose \(\Omega \subset {\mathbb {R}}^d\) has Lipschitz constant \(\tau < \tau _0\) and Q is a cube in \({\mathcal {D}}_{\mathcal {W}}(R)\) such that \(N(x_Q, S \ell (Q)) \le N\). Then, for all \({\tilde{K}} \ge K\), there exist cubes \(Q''_1, \ldots , Q''_{2^{(d-1)({\tilde{K}}-K)}}\) such that, for all j,

  1. (1)

    the center of \(Q_j''\) lies in \(\Sigma \),

  2. (2)

    \(u|_{Q_j''\cap \Omega }\) does not have zeros,

  3. (3)

    there exists \(Q_j' \in {\mathcal {D}}^{{\tilde{K}}}_{\mathcal {W}}(Q)\) such that \(Q''_j\) is a vertical translation of \(Q_j'\).

In particular, there exists \(\delta _0(N,S)>0\) such that

$$\begin{aligned} m_{d-1}\left( \bigcup _{i} \Pi (Q_i')\right) \ge \delta _0 m_{d-1}(\Pi (Q)) . \end{aligned}$$

These cubes \(Q''_j\) are the cubes that are contained in the ball B given by Lemma 5.1 and are vertical translation of cubes in \({\mathcal {D}}^{{\tilde{K}}}_{\mathcal {W}}(Q)\). From now on, given a cube \(Q \in {\mathcal {D}}_{\mathcal {W}}(R)\), we denote by t(Q) the unique cube \(Q'\) such that its center lies on \(\Sigma \) and \(Q'\) is a vertical translation of Q.

Next, we present a modified frequency function for which we prove good behavior as a consequence of Lemmas 4.1 and 5.1.

6.1 Modified frequency function

Let R be a cube in \({\mathcal {W}}\) such that it satisfies the conditions of Lemma 4.1 with \(S = S_1 \gg 1\) large enough so that \(CS_1^{-1/2}\) (also from the statement of Lemma 4.1) is small enough (we will specify the precise relation later). The use of this lemma gives us constants \(K_1 := K(S_1)\) and \(\delta _1 := \delta _0\) (that does not depend on \(S_1\)).

Consider also Corollary 6.1 with fixed \(N=2N_0+1\) (where \(N_0\) is the constant of Lemma 4.1) and \(S=S_2\) large enough but smaller than \(S_1\) (note that both constants are independent). The use of this corollary gives us constants \(K_2 := K(N, S_2)\) and \(\delta _2 := \delta _0(N,S_2)\). In particular, we may assume that \(K_2\) is smaller or equal than \(K_1\) and that \(CS_1^{-1/2}\) is small enough depending on \(\min (\delta _1,\delta _2)\).

We remark that the use of Lemma 4.1 and Corollary 6.1 with constants \(S_1\) and \(S_2\) respectively requires that the domain has small enough Lipschitz constant \(\tau \). For the rest of this section, we will denote \(\epsilon := CS_1^{-1/2}\), \(K:=K_1\), and \(\delta _0=\min (\delta _1,\delta _2)\) (in particular, \(\delta _0\) and \(S_1\) are independent constants).

Define

$$\begin{aligned} N(Q) := N(x_Q, S_1 \ell (Q)) \end{aligned}$$

for any \(Q \in {\mathcal {D}}_{{\mathcal {W}}}^{jK} (R)\) for \(j\ge 0\). Notice that \(1+2N(Q) \ge N(x_Q, S_2 \ell (Q))\) thanks to Proposition 3.8 (we assume \(x_Q\) and \(S_1 \ell (Q)\) are admissible for all children Q of R in the Whitney tree structure, thanks to \(\tau \) being small enough).

We define the modified frequency function \(N'(Q)\) for \(Q \in {\mathcal {D}}_{\mathcal {W}}^{jK}(R)\), \(j \ge 0\), inductively. For \(j=0\), we define \(N'(R) = \max (N(R),N_0/2)\). Assume we have \(N'(P)\) defined for all cubes \(P \in {\mathcal {D}}_{\mathcal {W}}^{iK}(R)\) for \(0\le i < j\). Fix \({\widehat{Q}} \in {\mathcal {D}}_{\mathcal {W}}^{(j-1)K}(R)\) and consider its vertical translation \(t({\widehat{Q}})\) centered on \(\Sigma \). Then:

  1. (a)

    if u restricted to \(t({\widehat{Q}})\cap \Omega \) has no zeros, define \(N'(Q) = N'({\widehat{Q}})/2\) for \(\lceil \delta _0\cdot {\text {card}}\{{\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\}\rceil \) of the cubes Q in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\) and \(N'(Q) = (1+\epsilon )N'({\widehat{Q}})\) for the rest of cubes in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\) (the particular choice is irrelevant),

  2. (b)

    if u restricted to \(t({\widehat{Q}})\cap \Omega \) has zeros, choose \(Q\in {\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\), and

    1. 1.

      if its vertical translation t(Q) satisfies that u restricted to \(t(Q)\cap \Omega \) has no zeros, define \(N'(Q) = N'({\widehat{Q}})/2\),

    2. 2.

      else define \(N'(Q) = \max (N(Q), N_0/2)\).

Note that if a cube Q satisfies that u restricted to \(t(Q)\cap \Omega \) has no zeros, then all its descendants in the Whitney cube structure will satisfy the same property and (a) applies to them. Alternatively, if a cube Q satisfies that u restricted to \(t(Q)\cap \Omega \) changes sign, then all its predecessors in the Whitney cube structure will satisfy the same and (b2) applies to them.

Now, a combination of Lemma 4.1 and Corollary 6.1 yields the following behavior for \(N'(Q)\) for \(Q \in {\mathcal {D}}_{\mathcal {W}}^{jK}(R), ~j\ge 0\). Consider a cube \({\widehat{Q}}\) and its vertical translation \(t({\widehat{Q}})\). Then:

  • If u restricted to \(t({\widehat{Q}})\cap \Omega \) has zeros and \(N({\widehat{Q}}) \ge N_0\), then Lemma 4.1 tells us that at least \(\lceil \delta _0\cdot {\text {card}}\{{\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\}\rceil \) cubes in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\) satisfy \(N(Q) \le N({\widehat{Q}})/2\). Moreover, in this case, \(N'(Q) = \max (N(Q), N_0/2) \le N({\widehat{Q}})/2 = N'({\widehat{Q}})/2\) where we have used that \(N({\widehat{Q}})>N_0\) and that (b) applies. For the rest of the cubes Q in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\), we have \(N'(Q) = \max (N(Q),N_0/2) \le (1+\epsilon )N({\widehat{Q}}) = (1+\epsilon ) N'({\widehat{Q}})\) where we have used again that \(N({\widehat{Q}})>N_0\) and (b) applies.

  • If u restricted to \(t({\widehat{Q}})\cap \Omega \) has zeros and \(N({\widehat{Q}}) < N_0\), then Corollary 6.1 enters in play and it tells us that at least \(\lceil \delta _0\cdot {\text {card}}\{{\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\}\rceil \) cubes Q in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\) satisfy that \(t(Q)\cap \Omega \) does not contain zeros of u. For these cubes, \(N'(Q) = N'({\widehat{Q}})/2 = \max (N({\widehat{Q}}),N_0/2)/2<N_0/2\). For the rest of the cubes Q in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\), we have \(N'(Q) = \max (N(Q), N_0/2) \le \max ((1+\epsilon )N({\widehat{Q}}), N_0/2) \le (1+\epsilon )N'({\widehat{Q}})\).

  • If u restricted to \(t({\widehat{Q}})\cap \Omega \) has no zeros, then we have defined \(N'(Q) = N'({\widehat{Q}})/2\) for \(\lceil \delta _0\cdot {\text {card}}\{{\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\}\rceil \) cubes Q in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\). We have defined \(N'(Q) = (1+\epsilon )N'({\widehat{Q}})\) for the rest of cubes Q in \({\mathcal {D}}^K_{\mathcal {W}}({\widehat{Q}})\) .

Summing up, for \({\widehat{Q}} \in {\mathcal {D}}_{\mathcal {W}}(R)\) and random \(Q \in {\mathcal {D}}_{\mathcal {W}}^K({\widehat{Q}})\), we have

$$\begin{aligned} N'(Q) \le {\left\{ \begin{array}{ll} N'({\widehat{Q}})/2, &{} \text{ with } \text{ probability } \text{ at } \text{ least }\, \delta _0, \\ N'({\widehat{Q}})(1+\epsilon ), &{} \text{ with } \text{ probability } \text{ at } \text{ most }\, 1-\delta _0. \end{array}\right. } \end{aligned}$$

This is similar to the behavior of the frequency function N given by Lemma 4.1 but without the restriction \(N'({\widehat{Q}}) \ge N_0\).

Let’s summarize the dependence of the constants that have appeared in this section (omitting its dependence on the dimension d and on \(L_A\) and \(\Lambda _A\) by assuming we are in a setting like the one described in Remark 2.3). On one hand, the constants \(K_2\) and \(\delta _2\) given by Corollary 6.1 are absolute since they depend on \(S_2\) and \(N = 2N_0 + 1\) which also are absolute constants. We do require \(\tau \) small enough to use Corollary 6.1. On the other hand, we have \(K_1\) depending on \(S_1\), \(\epsilon = CS_1^{-1/2}\), and an absolute constant \(\delta _1\) given by Lemma 4.1. To use Lemma 4.1, we require \(\tau \) small enough depending on \(S_1\). For the arguments that follow, we need \(\epsilon \) small enough depending on \(\delta _0 = \min (\delta _1, \delta _2)\). Though, since both constants (\(\epsilon \) and \(\delta _0\)) are independent, we can choose \(S_1\) large enough and, thus, we require \(\tau \) small enough (depending on \(S_1\)) to use Lemma 4.1.

6.2 Proof of Theorem 1.1

The idea behind the proof is that Lemma 4.1 allows us to use that most cubes in any generation of the Whitney tree satisfy \(N(x_Q, S \ell (Q)) \le N_0\). Then, we can apply Lemma 5.1 to these cubes, thus covering most of \(\Sigma \) by balls where u does not change sign.

Proof of Theorem 1.1

We will prove the result for the projection of a single cube \(\Pi (R)\). Afterwards, we can cover any compact in \(\Sigma \) by a finite union of such cubes which leaves stable the Minkowski dimension estimate.

For \(x \in \Pi (R)\), we denote by \(Q_j(x)\) the unique cube \(Q_j \in {\mathcal {D}}_{\mathcal {W}}^{jK}(R)\) such that \(x \in \Pi (Q_j)\) for some integer K large enough that will be fixed later. We will say that \(Q_j(x)\) is a good cube if \(N'(Q_j) \le \frac{1}{2} N'(Q_{j-1})\) and that it is bad otherwise.

Remark 6.2

Note that, with the previous definitions, \(N'(Q) < N_0/2\) implies that for all \(x \in t(Q)\cap \Sigma \) there is a neighborhood where u does not vanish in \(\Omega \). Thus we only need to study the Minkowski dimension of the set of points \(x \in \Pi (R)\) such that they are not in \(\Pi (Q)\) for some \(Q\in {\mathcal {D}}_{{\mathcal {W}}}(R)\) with \(N'(Q) < N_0/2\). Also, notice that the map \(\Pi : \Sigma \cap \Pi ^{-1}(\Pi (R)) \mapsto \Pi (R)\) is biLipschitz and thus it preserves Minkowski dimensions.

We define the goodness frequency of a point \(x \in \Pi (R)\) as

$$\begin{aligned} F_j(x) = \frac{1}{j} \#\{ \text {good cubes in } Q_1(x), \ldots , Q_j(x) \} \end{aligned}$$

for \(j\in {\mathbb {N}}\). We define \({\overline{F}}(x) = \limsup _{n \rightarrow \infty } F_n(x)\). Let \(\alpha (\delta _0)>0\) be such that

$$\begin{aligned} \frac{\delta _0}{1-\delta _0} \frac{1-\alpha }{\alpha } = 3 \end{aligned}$$

(in particular, \(\alpha <\delta _0\)) and \(\epsilon _0(\alpha )>0\) such that

$$\begin{aligned} \alpha = \frac{\log (1+\epsilon _0)}{\log (1+\epsilon _0) + \log 2}. \end{aligned}$$

Note that for any \(0<\epsilon <\epsilon _0\), we have

$$\begin{aligned} \left( \frac{1}{2} \right) ^\alpha (1+\epsilon )^{1-\alpha }<1. \end{aligned}$$
(6.1)

For all \(j>1\), define

$$\begin{aligned} \mu _j=\frac{1}{j} \log _2 \left( \frac{2N'(R)}{ N_0}\right) \ge 0. \end{aligned}$$

Claim

For all \(j>1\), the following holds

$$\begin{aligned} F_j(x) \ge \alpha + \mu _j \implies N'(Q_j(x)) < \frac{N_0}{2}. \end{aligned}$$

Proof of claim

We have that

$$\begin{aligned} N'(Q_j(x)) \le \left( \frac{1}{2} \right) ^{j(\alpha +\mu _j)}(1+ \epsilon )^{j(1-\alpha -\mu _j)} N'(R)< \left( \frac{1}{2} \right) ^{j \mu _j} (1+\epsilon )^{-j \mu _j} N'(R) < \frac{N_0}{2} \end{aligned}$$

by (6.1), and the definition of \(F_j(x)\) and \(\mu _j\). \(\square \)

Now, thanks to the previous claim and Remark 6.2, we can reduce the problem to studying the Minkowski dimension of the set of points

$$\begin{aligned} E = \{ x \in \Pi (R) ~|~ F_j(x) < \alpha + \mu _j, ~\forall j \in {\mathbb {N}} \}. \end{aligned}$$

If we consider a random sequence of cubes \((Q_j)_j\) with \(Q_0 = R\) and \(Q_j \in {\mathcal {D}}_{{\mathcal {W}}}^{K}(Q_{j-1})\), and let \(x \in \bigcap _{j \ge 0}\Pi (Q_j)\), the probability that \(F_j(x) \le \beta _j\) for \(j \in {\mathbb {N}}\) and \(\beta _j \in (0,1)\) is bounded above by

$$\begin{aligned} \sum _{i=0}^{\lfloor j \beta _j \rfloor } {j \atopwithdelims ()i} \delta _0^i (1-\delta _0)^{j-i} . \end{aligned}$$

Note that choosing randomly such a sequence is equivalent to choosing a random \(x \in \Pi (R)\) uniformly. In what follows we will assume that \(\beta _j\) satisfy \(2<\frac{\delta _0}{1-\delta _0} \frac{1-\beta _j}{\beta _j}<4\) for all \(j>0\), in particular \(\beta <\delta _0\). Let’s find an upper bound for the previous quantity for very large j:

$$\begin{aligned} \boxed {A}_j := \sum _{i=0}^{{\lfloor j \beta _j \rfloor }} {j \atopwithdelims ()i} (1-\delta _0)^{j-i} \delta _0^i = (1-\delta _0)^j\sum _{i=0}^{{\lfloor j \beta _j \rfloor }} {j \atopwithdelims ()i} \left( \frac{\delta _0}{1-\delta _0} \right) ^i. \end{aligned}$$

Observe that for \(\beta _j<1/2\) we have

$$\begin{aligned} {j \atopwithdelims ()k-1}< \frac{\beta _j}{1-\beta _j} {j \atopwithdelims ()k}, \quad \text {for } 0 < k \le \lfloor \beta _j j \rfloor . \end{aligned}$$

This is because

$$\begin{aligned} \frac{{j \atopwithdelims ()k-1}}{{j \atopwithdelims ()k}} = \frac{k! (j-k)!}{(k-1)! (j-k+1)!} = \frac{k}{j-k+1} < \frac{\beta _j}{1-\beta _j}. \end{aligned}$$

Iterating this inequality, we obtain

$$\begin{aligned} {j \atopwithdelims ()i}< \left( \frac{\beta _j}{1-\beta _j} \right) ^{\lfloor j \beta _j\rfloor -i} {j \atopwithdelims ()\lfloor j \beta _j \rfloor }, \quad \text{ for } i<\lfloor j \beta _j \rfloor . \end{aligned}$$

Using this observation we can bound \(\boxed {A}_j\) by

$$\begin{aligned} (1-\delta _0)^j\sum _{i=0}^{{\lfloor j\beta _j \rfloor }} {j \atopwithdelims ()i} \left( \frac{\delta _0}{1-\delta _0} \right) ^i \le (1-\delta _0)^j \left( \frac{\beta _j}{1-\beta _j} \right) ^{\lfloor j\beta _j\rfloor } {j \atopwithdelims ()\lfloor j\beta _j \rfloor } \sum _{i=0}^{{\lfloor j\beta _j \rfloor }} \left( \frac{\delta _0}{1-\delta _0} \frac{1-\beta _j}{\beta _j}\right) ^i . \end{aligned}$$

We use Stirling’s formula to approximate

$$\begin{aligned}{} & {} {j \atopwithdelims ()\lfloor j\beta _j \rfloor } \approx \frac{\sqrt{2\pi j} \left( \frac{j}{e} \right) ^{j}}{\sqrt{2\pi \beta _j j} \left( \frac{\beta _j j}{e} \right) ^{\beta _j j} \sqrt{2\pi (1-\beta _j) j} \left( \frac{(1-\beta _j )j}{e} \right) ^{(1-\beta _j )j}}\\{} & {} \qquad = \frac{1}{\sqrt{2\pi \beta _j(1-\beta _j)j}} \left( \frac{1}{\beta _j^{\beta _j} (1-\beta _j)^{1-\beta _j}}\right) ^j. \end{aligned}$$

We also estimate

$$\begin{aligned} \left( \frac{\beta _j}{1-\beta _j}\right) ^{\lfloor j \beta _j \rfloor } \approx \left( \frac{\beta _j}{1-\beta _j}\right) ^{ j \beta _j } \,\,\text { and }\,\,\,\, \sum _{i=0}^{{\lfloor j\beta _j \rfloor }} \left( \frac{\delta _0}{1-\delta _0} \frac{1-\beta _j}{\beta _j}\right) ^i \approx \left( \frac{\delta _0}{1-\delta _0} \frac{1-\beta _j}{\beta _j}\right) ^{j\beta _j} . \end{aligned}$$

Observe that the comparability constants in the previous approximations depend on the upper and lower bounds of \(\beta _j\) but not on j for j large enough depending on \(\delta _0\).

Summing everything up, we obtain

$$\begin{aligned} \boxed {A}_j \lesssim \frac{2}{\sqrt{2\pi \beta _j(1-\beta _j)j}} \underbrace{\left( \frac{(1-\delta _0)^{1-\beta _j} {\delta _0}^{\beta _j}}{\beta _j^{\beta _j} (1-\beta _j)^{1-\beta _j}} \right) ^j}_{z(\beta _j)^j}, \end{aligned}$$

for j large enough. Observe that \(z(\beta _j)<1\) for \(\beta _j<\delta _0\).

Now, we will choose a suitable covering of the set E by projections of cubes in \({\mathcal {D}}^{jK}_{{\mathcal {W}}}(R)\). First, pick \(\epsilon <\epsilon _0\) (equivalently \(S_1\) large enough, recall the discussion in Sect. 6.1). Observe that by choosing \(\epsilon \) we also fix K. For \(j \ge 1\), set

$$\begin{aligned} E_{j} := \{ x \in \Pi (R) ~|~ F_j(x) \le \alpha +\mu _j \}, \end{aligned}$$

so that \(E = \bigcap _j E_j\). Let’s upper bound the (K-adic) Minkowski dimension of E by finding a certain cover of \(E_j\) by projections of cubes in \({\mathcal {D}}^{jK}_{\mathcal {W}}(R)\) (note that there are \(M = 2^{(d-1)K}\) cubes in \({\mathcal {D}}^K_{\mathcal {W}}(R)\)).

Using the previous asymptotics (setting \(\beta _j = \alpha + \mu _j\)), we can cover \(E_j\) (for j large enough) with

$$\begin{aligned} C M^j\frac{2}{\sqrt{2\pi (\alpha +\mu _j)(1-\alpha - \mu _j)j}} z(\alpha +\mu _j)^j \end{aligned}$$

projections of cubes in \({\mathcal {D}}^{jK}_{\mathcal {W}}(R)\) and each of those cubes has side length \(M^{-j/(d-1)}\).

Now we are ready to upper bound the Minkowski dimension of the set E. We will use the following definition of upper Minkowski dimension

$$\begin{aligned} {\text {dim}}_{\overline{{\mathcal {M}}}} E = \limsup _{j\rightarrow \infty } \frac{\log \#(\{K-\text{ adic } \text{ cubes }\, Q\, \text{ of } \text{ side } \text{ length }\, K^{-j}\, \text{ that } \text{ satisfy } \,Q \cap E \ne \varnothing \})}{j\log K}. \end{aligned}$$

which is equivalent to the dyadic one in (1.1). By covering a single set \(E_j \supset E\) and making \(j\rightarrow \infty \), we obtain the following upper Minkowski dimension estimate

$$\begin{aligned} {\text {dim}}_{\overline{{\mathcal {M}}}} (E)&\le \lim _{j \rightarrow \infty } \frac{ j (\ln M + \ln z(\alpha + \mu _j)) + \ln \left( \frac{2}{\sqrt{2\pi (\alpha +\mu _j)(1-\alpha - \mu _j)j} } \right) }{ {(d-1)^{-1}j } \ln M} \\&= (d-1) \frac{\ln M + \ln z(\alpha )}{\ln M} < d-1 \end{aligned}$$

since \(z(\alpha )<1\). \(\square \)

6.3 Planar case of Theorem 1.1

In the planar case, Theorem 1.1 asserts that we can cover any compact \(K \subset \Sigma \) by balls where u does not change sign inside apart from a finite set of points. Moreover, this is valid for general Lipschitz domains (and domains with worse boundary regularity).

Proof of Theorem 1.1 in the planar case

Without loss of generality, suppose that \(\Omega \) is simply connected and bounded.

By [4, Theorem 16.1.4], there exists a K-quasiconformal map \(\phi : {\mathbb {C}} \rightarrow {\mathbb {C}}\) such that \(u= w \circ \phi \) with w harmonic in \(\phi (\Omega )\). Since \(\phi \) is biHölder continuous it is enough to prove the desired result for harmonic functions in Jordan domains.

Now, consider a conformal mapping between \(\phi (\Omega )\) and the disk \({\mathbb {D}}\) which extends to a homeomorphism up the boundary, and let v be the induced harmonic function in the disk.

Denote by \({\tilde{\Sigma }}\) the open set in \(\partial {\mathbb {D}}\) where v vanishes and by \({\tilde{E}}\) the set of points in \({\tilde{\Sigma }}\) such that for every neighborhood v changes sign. Then \({\tilde{E}}\) must be a discrete set. This is because it coincides with the zero set of \(\nabla v\) which is holomorphic (we can locally extend v to \({\mathbb {D}}^c\) by reflection using the Kelvin transform near \({\tilde{\Sigma }}\)). Thus, since it is a discrete set, it is countable and finite inside any compact. Note that all maps we have considered are homeomorphisms, thus the set where v changes sign in every neighborhood is transported to another countable discrete set in \(\Sigma \subset {\overline{\Omega }}\). \(\square \)

6.4 Estimates on the measure of nodal sets in the interior of the domain

Theorem 6.1 in [24] estimates the \((d-1)\)-dimensional Hausdorff measure of the nodal set in a cube in terms of its doubling index, which is a quantity intimately related to the frequency function used in this paper. We present the following reformulation of Logunov’s theorem avoiding the use of doubling indices.

Theorem 6.3

There exist positive constants rRC depending on the Lipschitz constant \(L_A\) of A(x), ellipticity constant \(\Lambda _A\) of A(x), and dimension d such that the following statement holds. Let u be a solution of \({\text {div}}(A\nabla u)=0\) on \(B(0,R) \subset {\mathbb {R}}^d\). Then, for any cube \(Q \subset B(0,r)\), we have

$$\begin{aligned} {\mathcal {H}}^{d-1}(\{u = 0\} \cap Q) \le C \ell (Q)^{d-1} (N(x_Q, 16{\text {diam}}(Q))+1)^\alpha \end{aligned}$$

for certain \(\alpha = \alpha (d) > 0\) and where \(x_Q\) is the center of Q.

Remark 6.4

If we assume \(N(x_Q, 16{\text {diam}}(Q)) > N_0\) for some \(N_0\) positive, we can rewrite the previous theorem as

$$\begin{aligned} {\mathcal {H}}^{d-1}(\{u = 0\} \cap Q) \le C \ell (Q)^{d-1} (N(x_Q, 16{\text {diam}}(Q)))^\alpha \end{aligned}$$

where now C depends also on \(N_0\) and \(\alpha \).

6.5 Proof of Theorem 1.5

To prove Theorem 1.5 we will follow the ideas of [28] but exchanging the use of the Donnelly–Fefferman estimate for the size of nodal sets (see [10]) by Logunov’s estimate (Theorem 6.3). This gives rise to a worse estimate (polynomial in the frequency) than the one of [28] (which is linear in the frequency but only valid for harmonic functions).

Proof of Theorem 1.5

Let Q be a small enough cube of the Whitney structure (so that we can use the modified frequency function defined in Sect. 6.1). Again, we will use the notation t(Q) for the unique cube \(Q'\) with center on \(\Sigma \) such that \(Q'\) is a vertical translation of Q.

Claim

The following equation holds

$$\begin{aligned} {\mathcal {H}}^{d-1}(\{u = 0\} \cap t(Q) \cap K) \le C_0 N'(Q)^\alpha \ell (Q)^{d-1} \end{aligned}$$
(6.2)

for any K compact inside \(\Omega \) with \(C_0\) and \(\alpha \) independent of K.

Proof of claim

Note that Eq. (6.2) holds for all cubes Q small enough, since \(t(Q) \cap K = \varnothing \) if Q is small enough. This is because \({\text {dist}}(K,\Sigma )>0\). We will proceed to prove this estimate by induction going from small cubes to large cubes.

Assume it holds for all small cubes with \(\ell (Q)<s\) . Now choose a larger cube P in the Whitney cube structure with \(\ell (P) < 2^K \ell (Q)\) (with K given by Lemma 4.1 as discussed in Sect. 6.1). Given such a cube P, we can cover \(t(P) \cap \Omega \) with small cubes \(t(Q_i)\) (intersecting the boundary) where \(Q_i \in {\mathcal {D}}_{{\mathcal {W}}}^K(P)\) and with small cubes \(Q_i'\) far from the boundary (small enough so that we can apply Theorem 6.3 on them).

Using that the Lipschitz constant of \(\partial \Omega \) is small, we can bound the number of small cubes \(Q_i'\) necessary. Moreover, using Lemma 3.14, we can bound \(N(x_{Q'}, 16 {\text {diam}}(Q')) < 2 N(P) + 1\). Note that \(N(P) \le N'(P)\) in the case that \(t(P) \cap \Omega \cap \{ u = 0 \} \ne \varnothing \). This allows us to bound the size of the nodal set on \(\bigcup Q_i' \cap \Omega \) using Theorem 6.3 by

$$\begin{aligned} \sum _{Q_i'} {\mathcal {H}}^{d-1} (\{u = 0\} \cap Q_i') \le C_1 N'(P) \ell (P)^{d-1}. \end{aligned}$$

We still need to bound the size of the nodal set in the boundary cubes \(t(Q_i)\), which satisfy \(N'(Q_i) \le (1+\epsilon ) N'(P)\). Moreover, we know that at least for \(\lceil \delta _0 {\text {card}}\{{\mathcal {D}}_{\mathcal {W}}^K(P)\}\rceil \) cubes \(Q_i\) we have \(N'(Q_i) \le \frac{N'(P)}{2}\). Now we can use the induction hypothesis

$$\begin{aligned} {\mathcal {H}}^{d-1}(\{u = 0\} \cap K \cap \bigcup _{Q_i} t(Q_i))&\le \sum _{ N'(Q_i)> N'(P)/2} {\mathcal {H}}^{d-1}(\{u = 0\} \cap K \cap t(Q_i)) \\&~~ + \sum _{N'(Q_i)\le N'(P)/2} {\mathcal {H}}^{d-1}(\{u = 0\} \cap K \cap t(Q_i)) \\&\le \sum _{ N'(Q_i) > N'(P)/2} C_0 N'(Q_i)^\alpha \ell (Q_i)^{d-1}\\&~~+ \sum _{N'(Q_i)\le N'(P)/2} C_0 N'(Q_i)^\alpha \ell (Q_i)^{d-1} \\&\le C_0 N'(P)^\alpha \ell (P)^{d-1} \left( (1+\epsilon )^\alpha (1 - \delta _0) + \frac{\delta _0}{2^\alpha } \right) . \end{aligned}$$

We choose \(\epsilon \) small enough (by increasing \(S_1\)) so that

$$\begin{aligned} (1+\epsilon )^\alpha (1 - \delta _0) + \frac{\delta _0}{2^\alpha } < 1 \end{aligned}$$

noting that \(\delta _0\) does not depend on \(S_1\) or \(\epsilon \). Finally, we choose \(C_0\) large enough so that it absorbs all terms, that is,

$$\begin{aligned} C_0 \left( (1+\epsilon )^\alpha (1 - \delta _0) + \frac{\delta _0}{2^\alpha } \right) + C_1 < C_0 . \end{aligned}$$

Note that the previous estimates do not depend on the compact K chosen and we prove the claim. \(\square \)

To treat a general (small) ball B centered at \(\Sigma \), we first cover it by a comparable cube Q centered at \(\Sigma \). Now, we choose a translate and dilation of the dyadic cube structure of \({\mathbb {R}}^d\) such that \(Q = t(P)\) for some P in the Whitney cube structure and we apply the previous claim. \(\square \)

Remark 6.5

In the statement of Theorem 1.5, the point \({\tilde{x}}\) that appears is the center of a particular Whitney cube appearing in the proof. Nonetheless, Lemma 3.14 (and that the Lipschitz constant \(\tau \) of the boundary is small to preserve admissibility) gives us a lot of freedom to choose \({\tilde{x}}\).

6.6 \((d-1)\)-dimensional Hausdorff measure of Dirichlet eigenfunctions

Theorem 1.5 allows us to study the zero set of solutions of the Dirichlet eigenvalue problem

$$\begin{aligned}{\left\{ \begin{array}{ll} {\text {div}}(A \nabla u_\lambda ) = -\lambda u_\lambda ,~ \text { in } \Omega , \\ u_\lambda = 0, ~ \text { on } \partial \Omega . \end{array}\right. }\end{aligned}$$

In fact, one can show that

$$\begin{aligned} {\mathcal {H}}^{d-1}(\{u_\lambda = 0\}) \le C(\Omega , \Lambda _A, L_A) \lambda ^{\frac{\alpha }{2}} \end{aligned}$$
(6.3)

for bounded domains \(\Omega \) with local Lipschitz constant small enough for some \(\alpha = \alpha (d) > 1\). For a detailed account of the proof in the harmonic case (and a sharper result), see Section 6 in [28]. We will only briefly sketch the main ideas behind its proof. Also note that this problem is intimately related to Yau’s conjecture on nodal sets of Laplace eigenfunctions in manifolds (see [10, 24, 25, 27]).

The first step consists in passing from eigenfunctions to solutions of \({\text {div}}(A\nabla u)=0\). Consider the function \(u(x,t) = u_\lambda (x) \hbox {e}^{\sqrt{\lambda }t}\) in the cylinder domain \(\Omega \times {\mathbb {R}} \subset {\mathbb {R}}^{d+1}\). Let

$$\begin{aligned} {\tilde{A}}(x) = \begin{pmatrix} A(x) &{} 0 \\ 0 &{} 1 \end{pmatrix}, \end{aligned}$$

then we have that u solves

$$\begin{aligned} {\text {div}}({\tilde{A}} \nabla u) = \underbrace{{\text {div}}(A \nabla u_\lambda )}_{-\lambda u_\lambda (x)} \hbox {e}^{\sqrt{\lambda }t} + \lambda u_\lambda (x) \hbox {e}^{\sqrt{\lambda }t} = 0 . \end{aligned}$$

Clearly, we have \(\{ u(x,t) = 0 \} = \{ u_\lambda (x) = 0 \}\times {\mathbb {R}} \). Thus, we can restrict us to the study of the nodal set of u(xt).

The next necessary step is the Donnelly–Fefferman frequency estimate [10]. For small balls B contained in the domain, it is shown in [10, 26] that \(N^u(x_B, r(B)) \le C(\Omega , \Lambda _A, L_A) \sqrt{\lambda }\). The previous result is also true for balls intersecting the boundary (see Lemma 10 in [28] for a proof in the harmonic case).

Finally, using the previous estimate together with Theorems 1.5 and 6.3, one obtains the result in (6.3).

7 Proof of Corollary 1.6

Theorem 1.1 tells us that we can decompose \(\Sigma \) in its intersection with a countable family of balls \((B_i)_i\) and a set of Hausdorff dimension smaller than \(d-1\) by taking an exhaustion of \(\Sigma \) by compacts. Thanks to countable additivity, we only need to prove that

$$\begin{aligned} {\mathcal {H}}^{d-1}\left( \{x \in \Sigma \,|\, \partial _\nu u(x) = 0\}\cap B \right) = 0 \end{aligned}$$

for any ball \(B\in (B_i)_i\) given by the decomposition of Theorem 1.1.

Before starting the proof, we define the concept of \({\mathcal {A}}_\infty \) weight.

Definition 7.1

We say that a measure \(\omega \in {\mathcal {A}}_\infty (\sigma )\) if there exist \(0<\gamma _1, \gamma _2 < 1\) such that for all balls B and subsets \(E \subset B\), \(\sigma (E) \le \gamma _1 \sigma (B)\) implies \(\omega (E) \le \gamma _2 \omega (B)\).

Proof of Corollary 1.6

Consider B centered on \(\Sigma \) such that \(u|_{B\cap \Omega }\) does not change sign. Without loss of generality, we assume that u is positive.

By Dahlberg’s theorem [8], harmonic measure for the domain \(B\cap \Omega \) is an \({\mathcal {A}}_\infty \) weight with respect to surface measure. By [12], since the matrix A(x) is uniformly elliptic and has Lipschitz coefficients, its associated elliptic measure \(\omega _A\) is another \({\mathcal {A}}_\infty \) weight. In particular, it is well known that this implies that the density \(\frac{d \omega _A}{\hbox {d}\sigma }\) can only vanish in a set of zero surface measure.

On the other hand, the density of elliptic measure is comparable with \((A\nabla g, \nu )\) at the boundary (where g is the Green function with pole outside 2B). By the boundary Harnack inequality (see [11] for example), since u is positive in \(B\cap \Omega \), we have that \(A\nabla u\) on \(\Sigma \cap B\) is comparable to \(A\nabla g\). This finishes the proof. \(\square \)

Remark 7.2

There is also a different approach to proving Corollary 1.6, which is the one adopted in [33] for harmonic functions. The ingredients are Lemma 4.1, [2, Lemma 0.2] (which is also valid for the type of PDEs we consider, see the paragraph below the proof of [2, Lemma 2.2], also [33, Lemma 4.3]), and a modification of [33, Lemma 4.1]. In particular, the tools of Sects. 5 and 6 are not indispensable for this result.

8 Proof of Corollary 1.8

Definition 8.1

We define a non-truncated cone \({\tilde{C}}_\tau \) with aperture \(\tau \in {\mathbb {R}}\) and vertex at 0 as

$$\begin{aligned} {\tilde{C}}_\tau (0) = \{(y',y'') \in {\mathbb {R}}^{d-1} \times {\mathbb {R}} ~|~ y'' > \tau |y'|\}. \end{aligned}$$

Notice that when \(\tau = 0\), then \({\tilde{C}}_0\) is a half space and when \(\tau <0\), \({\tilde{C}}_\tau \) is a non-convex cone. A truncated cone \(C_{\tau ,s}\) is a non-truncated cone \({\tilde{C}}_\tau \) intersected with the ball B(0, s).

First we will prove the result for harmonic functions.

Proof of Corollary 1.8 in the harmonic case

Let \(x \in B\cap \Sigma \) for some ball B where u does not vanish given by Theorem 1.1. Assume without loss of generality that \(u|_{B\cap \Omega } >0\).

Since \(\Sigma \) is Lipschitz with Lipschitz constant \(\tau \), we can find a small truncated cone \(C_{\tau ,s}\) of aperture \(\tau \) with vertex at x and contained in \(\Omega \).

Let g be the Green function (for the Laplacian) with pole at infinity of the non-truncated cone \({\tilde{C}}_\tau \). Since \(u|_{C_{\tau ,s}}\) is nonnegative up to the boundary, we can lower bound it by some adequate multiple of g (that is \(u > rsim g\) in \(C_{\tau ,s}\)) by boundary Harnack inequality. Notice that g is of the form \(g(x) = g_r(|x|)g_\theta (\frac{x}{|x|})\) where \(g_\theta \) is the first Dirichlet eigenfunction of the Laplace-Beltrami operator \(\Delta \) in the domain \({{\tilde{C}}_\tau \cap \partial B(0,1)}\) with eigenvalue \(\lambda _\tau \) and \(g_r(|x|) = |x|^{-\frac{d}{2} + 1 + \frac{\sqrt{(d-2)^2-4\lambda _\tau }}{2}}\) (see [1, Theorem 1.1]). Thus \(g_r\) gives an upper bound on the order of vanishing at the origin. Also notice that \(\lambda _0 = 1-d\) (when \({\tilde{C}}_0\) is a half space) and thus \(g_r(|x|) = |x|\). Since the Dirichlet eigenvalues \(\lambda _\tau \) of \({\tilde{C}}_\tau \cap \partial B(0,1)\) for the Laplace-Beltrami operator vary continuously with the aperture \(\tau \) of \({\tilde{C}}_\tau \), we can ensure that the order of vanishing of g is close enough to 1 by making \(\tau \) small enough. The continuity of the variation of the eigenvalues with the aperture can be easily shown using the Rayleigh quotient.

For the lower bound on the order of the vanishing at the origin, consider a cone \({\tilde{C}}_{-\tau }\) of aperture \(-\tau \) (concave cone) and its Green function g with pole at the infinity. Now \(g|_{\Omega \cap {\tilde{C}}} > rsim u\) and we can follow the same argument. \(\square \)

Next, we deal with the elliptic case, but first, we need several lemmas.

Lemma 8.2

Let u be a solution of \({\text {div}}(A\nabla u) = 0\) in \(\Omega \) and \(x_0 \in \Omega \cup \Sigma \). Then the vanishing order \(\alpha \) of u at \(x_0\) satisfies

$$\begin{aligned} \alpha (x_0) = \lim _{r \downarrow 0} \log _2 \frac{\sqrt{H(x_0,2r)}}{\sqrt{H(x_0,r)}} \end{aligned}$$

when the limit exists.

Proof

The proof has two parts. First, we see that

Notice that for r small enough, we have

thanks to Cauchy–Schwarz and Lemma 3.12. On the other hand, if we let \(x_* \in \overline{B(x_0,r)}\) be such that \(|u(x_*)| = \sup _{B(x_0,r)} |u|\), then

using standard estimates for solutions of elliptic PDEs.

The second part consists in showing that

$$\begin{aligned} \lim _{r \downarrow 0} \log _2 \frac{\sqrt{H(x_0,2r)}}{\sqrt{H(x_0,r)}} = \alpha \end{aligned}$$

implies

$$\begin{aligned} \sqrt{H(x_0,r)} \le C_\gamma r^\gamma , \quad 0<\gamma <\alpha , ~\text { and }~ \lim _{r\rightarrow 0} \frac{\sqrt{H(x_0,r)}}{r^\gamma } = \infty , \quad \gamma >\alpha . \end{aligned}$$

Fix \(\gamma <\alpha \). Then there exists some \(k_\gamma >0\) such that for all \(k>k_\gamma \), we have

$$\begin{aligned} \log _2 \frac{\sqrt{H(x_0,2^{-k+1})}}{\sqrt{H(x_0,2^{-k})}} > \gamma . \end{aligned}$$

Then, for all n large enough, we have

$$\begin{aligned} \sqrt{H(x_0, 2^{-n})} = \sqrt{H(x_0,1)}\, \prod _{j=1}^n \frac{\sqrt{H(x_0,2^{-j})}}{\sqrt{H(x_0,2^{-j+1})}} < C 2^{-\gamma (n-k_\gamma )} = C' \left( 2^{-n} \right) ^\gamma . \end{aligned}$$

Now, fix \(\gamma >\alpha \). As before,there exists some \(k_\gamma >0\) such that for all \(k>k_\gamma \), we have

$$\begin{aligned} \log _2 \frac{\sqrt{H(x_0,2^{-k+1})}}{\sqrt{H(x_0,2^{-k})}} < \gamma - \delta . \end{aligned}$$

for some small \(\delta >0\). Finally, for all n large enough, we obtain

$$\begin{aligned} \sqrt{H(x_0, 2^{-n})} = \sqrt{H(x_0,1)}\, \prod _{j=1}^n \frac{\sqrt{H(x_0,2^{-j})}}{\sqrt{H(x_0,2^{-j+1})}}> C 2^{-(\gamma +\delta )(n-k_\gamma )} > C' \left( 2^{- n}\right) ^\gamma 2^{\delta n}. \end{aligned}$$

Since \(\lim _{n\rightarrow \infty }2^{\delta n} = \infty \), this finishes the proof. \(\square \)

Lemma 8.3

Let u be a positive solution to \({\text {div}}(A\nabla u) = 0\) in a cone \(C_{\tau ,s}\) such that \(u = 0\) on \(\partial C_{\tau ,s}\cap B(0,s)\). Assume also that \(A(0) = I\). Then, its frequency N(0, r) is bounded above for \(0<r<\frac{s}{2}\).

Proof

Remember that

Using that u extended by 0 outside of \(C_{\tau ,s}\) is a subsolution, by Caccioppoli’s inequality we have

By Remark 3 (page 953) in [2], we obtain the doubling property

uniformly for all r small enough. The remark is stated for convex domains, but the condition needed is that the domain is star-shaped with respect to 0. In the case of cones, this is trivially true. Using Lemma 3.12, we obtain that

Summing up, we get

for all r small enough. \(\square \)

The following lemma shows that the blow-up of positive solutions in cones converges to the Green function for the Laplacian in the domain \({\tilde{C}}_\tau \) with pole at \(\infty \) (see the proof of Corollary 1.8 in the harmonic case).

Lemma 8.4

Let u be a positive solution of \({\text {div}}(A\nabla u)=0\) in a truncated cone \(C_{\tau ,s}\) that vanishes on \(\partial C_{\tau ,s} \cap B(0,s)\) and assume that \(A(0) = I\). Consider any sequence of radii \(r_k \downarrow 0\) (such that \(r_1 < |p|\)). Let

Then \(u_k\) converges in \(W^{1,2}_{loc}({\tilde{C}}_\tau )\) and in \(C^{1,\alpha }_{loc}\left( \overline{{\tilde{C}}_\tau } \backslash \{0\} \right) \) to a multiple of the Green function g with pole at \(\infty \) for the Laplacian in \({\tilde{C}}_\tau \) for some exponent \(0<\alpha <1\). In particular, u and g have the same vanishing order at 0.

Proof

Without loss of generality assume that \(s>2\) and \(r_1=1\). Clearly, \(u \in W^{1,2}( C_{\tau ,1})\) and \(u_k \in W^{1,2}( C_{\tau , {1/r_k}})\) for all \(k>0\). Also notice that \(N^u(0,r_k) = N^{u_k}(0,1)\) where \(N^{u_k}\) is the frequency for the new PDE. Moreover, each \(u_k\) satisfies \(1 \approx H^{u_k}(0,1)\) and \(\Vert \nabla u_k \Vert ^2_{L^2(C_{\tau ,1})} \approx N^{u_k}(0,1)\). Observe that we can also bound \(\Vert \nabla u_k \Vert _{L^2(C_{\tau ,1/r_j})}\) and \(H^{u_k}(0,r_j)\) for any \(j \le k\) (with bound depending on \(r_j\)).

Thanks to Lemma 8.3, we have that the sequence \((u_k)_k\) is bounded in Sobolev norm in any bounded set. Moreover, by boundary Schauder estimates (see Lemma 6.18 in [16]), \(u_k\in C^{1,\alpha }(K)\) for any compact \(K \subset \overline{{\tilde{C}}_\tau } \backslash \{0\}\) (for k large enough depending on K). By Arzelà-Ascoli, there is a subsequence \((u_{k_j})_j\) that converges in norm \(C^1\) to \({\tilde{u}}\) in \(\overline{ C_{\tau ,1}}\backslash B_{1/8}\).

Moreover, we can also assume that \({\tilde{u}}\) is a weak limit in \(W^{1,2}_\text {loc}({\tilde{C}}_\tau )\). Thus, \({\tilde{u}}\) is harmonic in \({\tilde{C}}_\tau \). To see this, fix any compact \(K \subset \subset {\tilde{C}}_\tau \). Then, for all \(\phi \in C_C^1(K)\), we have

On the other hand, since \({\tilde{u}}\) is the weak limit of \(u_k\), we have

The term \({\boxed {A}}\) is zero by the definition of weak solution and we can estimate \({\boxed {B}}\) as

Summing up, we get that \({\tilde{u}}\) is harmonic in K.

Claim

The only functions which are positive and harmonic in \({\tilde{C}}_\tau \) are the multiples of the Green function g for the Laplacian in \({\tilde{C}}_\tau \) with pole at \(\infty \).

For the proof of the claim see [18, Lemma 3.7].

Since we have \(C^1\) convergence away from the pole and for all \(k>0\), the multiple of the Green function in the claim is fixed. Thus, the convergence does not depend on the sequence \(r_k\) chosen and is not up to subsequences. For this reason, we assume without loss of generality that \(r_k = 2^{-k+1}\).

We will see now that the limit

$$\begin{aligned} \lim _{r \downarrow 0} \log _2 \sqrt{H^u(x, 2r)} - \log _2 \sqrt{H^u(x,r)} \end{aligned}$$

exists and by Lemma 8.2 this coincides with the order of vanishing at zero.

If \(r\in (1/2^k, 1/2^{k-1})\), then

$$\begin{aligned} \log _2 \sqrt{H^u(0, 2r)} - \log _2 \sqrt{H^u(0,r)} = \log _2 \frac{\sqrt{H^{u_{k-1}}(0, 2^{k-1}r)} }{ \sqrt{H^{u_{k-1}}(0,2^{k-2}r)}}. \end{aligned}$$

Since \(r\in (1/2^k, 1/2^{k-1})\), this happens in the region where \(u_{k}\) converges to \({\tilde{u}}\) in \(C^1\) norm. Thus \(H^{u_k}(0,r) \rightarrow _{k \rightarrow \infty } H^{{\tilde{u}}}(0,r)\) for \(1/8<r<1\). By Lemma 8.2 this implies that both u and \({\tilde{u}}\) have the same vanishing order. \(\square \)

The general elliptic case is a direct consequence of the previous lemma following the same proof as in the harmonic case.

9 Example with \({\text {dim}}_{{\mathcal {H}}}(\{ x\in \Sigma ~| \lim _{r \downarrow 0} {\omega (B(x,r))}{r^{1-d}} = 0\}) > d-1-\epsilon \)

The following example by Xavier Tolsa shows that in a Lipschitz domain \(\Omega \) (even with small Lipschitz constant) there is no hope for a (non-trivial) Hausdorff dimension bound of the set of points of \(\Sigma \) where \(\partial _\nu u(x) = 0\).

Remark 9.1

We are interested in the normal derivative, but it may not exist at every point \(x \in \Sigma \). Nonetheless, since we are in a Lipschitz domain \(\Omega \) for every point \(x \in \Sigma \) we can consider a non-tangential cone \(C_\tau (x)\) contained in the domain. Thus, we can consider a non-tangential approach to the normal derivative. That is, for \(x\in \Sigma \), we define

$$\begin{aligned} \nabla _{nt} u(x) = \limsup _{\begin{array}{c} y \rightarrow x \\ y \in C_\tau (x) \end{array}} \frac{|u(y)-u(x)|}{|y-x|} . \end{aligned}$$

We will show that the set \(\{x \in \Sigma \,|\, \nabla _{nt} u(x) = 0\}\) can be very large (in terms of Hausdorff dimension).

The following lemma shows that non-tangential derivatives for positive harmonic functions are closely related with the density of harmonic measure.

Lemma 9.2

Assume u is positive and harmonic in \(\Omega \) and vanishes in \(\Sigma \). Then, for \(x\in \Sigma \), \(\nabla _{nt} u(x) = 0\) if and only if \(\lim _{r\downarrow 0} \frac{\omega (B(x,r))}{r^{d-1}} = 0\) where \(\omega \) is the harmonic measure for the Laplacian in \(\Omega \).

Proof of Remark 9.1

Fix a point \(p \in \Omega \) far from \(\Sigma \) and consider the Green function g with pole at p. Then, in a neighborhood of \(\Sigma \), the boundary Harnack inequality (see [11]) implies that the non-tangential derivative of u is 0 if and only if the non-tangential derivative of g is 0 wherever one of the two exists (if one exists and is 0 the other exists too by boundary Harnack inequality). This does not depend on the pole p chosen.

Now, the non-tangential derivative of g is 0 if and only if \(\lim _{r \downarrow 0} \frac{\omega (B(x,r))}{r^{d-1}} = 0\). This is a consequence of [8, Lemma 1] which shows

$$\begin{aligned} r^{d-2} g(x+Cre_d) \approx \omega ^p(B(x,r)) \end{aligned}$$

for some C depending on the dimension and the Lipschitz constant of the domain. \(\square \)

Now we can start setting up an appropriate domain. Consider, for \(\lambda \in (0,1)\), the \(\lambda \)-Cantor set defined as

$$\begin{aligned} {\mathcal {C}}_\lambda = \bigcap _{n=1}^\infty E_n^\lambda \end{aligned}$$

where \(E_0^\lambda = [0,1]\) and \(E_k^\lambda = \frac{1-\lambda }{2}E_{k-1}^\lambda \cup (\frac{1+\lambda }{2}+\frac{1-\lambda }{2}E_{k-1}^\lambda )\) for \(k\ge 1\). We will refer to the intervals in \([0,1]\backslash E_k^\lambda \) by gaps.

Remark 9.3

The set \({\mathcal {C}}_\lambda \) has Hausdorff dimension between 0 and 1 depending on \(\lambda \), but by making \(\lambda \) small enough we can obtain a set with dimension arbitrarily close to 1. From now, on we will denote it by \(s = s(\lambda ) = \dim _{{\mathcal {H}}} {\mathcal {C}}_\lambda \).

Remark 9.4

If \(\lambda =1/(2k+1)\) for some \(k\in {\mathbb {N}}\), then the set \({\mathcal {C}}_\lambda \) coincides with the set of real numbers in [0, 1] such that its decimal expansion in basis \(2k+1\) does not contain the digit k. Instead of choosing \(\lambda \), we will choose k large enough so that the Hausdorff dimension s of \({\mathcal {C}}_\lambda \) is as close as we want to 1.

Theorem 9.5

Let \(\lambda = 1/(2k+1)\) for some \(k\in {\mathbb {N}}\), and \(s=s(\lambda ) = {\text {dim}}_{{\mathcal {H}}}({\mathcal {C}}_\lambda )\). Then, \({\mathcal {H}}^s\)-a.e. \(x \in {\mathcal {C}}_\lambda \) satisfies that each possible digit \(\{0,1,\ldots ,k-1,\) \(k+1, \ldots , 2k\}\) in its decimal representation in basis \(2k+1\) appears with the same asymptotic frequency 1/(2k).

The proof of the theorem is analogous to the proof of Borel’s normal number theorem. Also, we will say that the points \(x \in {\mathcal {C}}_\lambda \) that satisfy this are \({\mathcal {C}}_\lambda \)-normal.

Fix \(a\in (0,1)\) and let

$$\begin{aligned} \Omega _\lambda := B(0,2) \cap \bigcup _{p \in {\mathcal {C}}_\lambda } \{C_a(p)\} \subset {\mathbb {R}}^2, \end{aligned}$$

where \(C_a(p)\) are vertical open cones of aperture a with vertex at p. Thus, \(\Omega _\lambda \) is the union of all the open cones with aperture a centered at a point of the Cantor set \({\mathcal {C}}_\lambda \). The domain \(\Omega _\lambda \) clearly has Lipschitz boundary and its Lipschitz constant can be made arbitrarily small as it depends only on the aperture of the cones a.

Remark 9.6

Let the interval \((\xi _1, \xi _2)\) be a gap in \([0,1]\backslash E_j^\lambda \). Then \(\partial \left( C_a(\xi _1) \cup C_a(\xi _2)\right) \cap \{(x,y)\in {\mathbb {R}}^2\,|\, x \in (\xi _1,\xi _2)\} \subset \partial \Omega _\lambda \). In other words, the boundary of \(\partial \Omega _\lambda \) looks like a cone (pointing upwards) where the Cantor set \({\mathcal {C}}_\lambda \) has gaps.

Note that, if \(\lambda = 1/(2k+1)\), the gaps correspond to subintervals of [0, 1] where all the numbers have the digit k in the position j of the decimal expansion in base \(2k+1\).

Now we will prove that every \({\mathcal {C}}_\lambda \)-normal point \((x,0) \in {\mathcal {C}}_\lambda \subset {\mathbb {R}} \cap {\overline{\Omega }}_\lambda \) satisfies that the density of harmonic measure at (x, 0) is 0.

Proposition 9.7

Let \(\Omega _\lambda \) be the Lipschitz domain defined above. Let (x, 0) be a \({\mathcal {C}}_\lambda \)-normal point in \({\mathcal {C}}_\lambda \). Then \(\lim _{r\downarrow 0} \frac{\omega (B(x,r))}{r^{d-1}} = 0\) in (x, 0) where \(\omega \) is the harmonic measure of \(\Omega _\lambda \) with pole in (x, 1).

Proof

Theorem 6.2. in [15, page 149] (called \(\hbox {d}x/\theta (x)\) estimate) tells us

(9.1)

for r small enough where \(s\Theta (s)\) is the length of the connected arc in \(\Omega \cap \partial B((x,0),s)\) that separates (x, 0) and the pole (x, 1). We want to prove that

$$\begin{aligned} \limsup _{r\rightarrow 0} \frac{\omega (B((x,0),r))}{r} = 0 \end{aligned}$$

which is a consequence of

by inequality (9.1).

Since the domain is contained in the upper half plane and \(x\in {\mathbb {R}}\) we have that \(0<\Theta (s) \le \pi \). This implies that we can change the \(\limsup \) by a \(\lim \). Also we can rewrite the integral as

Now we will use that x is \({\mathcal {C}}_\lambda \)-normal. This implies that, asymptotically, for a fixed proportion of digits in the decimal expansion of x in basis \(2k+1\) the digit is \(k-1\) or \(k+1\).

If the j-th digit in the decimal expansion of x in basis \(2k+1\) is either \(k-1\) or \(k+1\), then for \(s \in [2.1(2k+1)^{-j}, (2k+1)^{1-j}]\) we have that \(\Theta (s) < \pi - \epsilon \) for some \(\epsilon >0\) depending only on the aperture of the cones a. This is because the arc of circumference centered at (x, 0) with radius s meets with a cone \(C_a(p)\) corresponding to a gap in \([0,1]\backslash E_j^\lambda \) (see Remark 9.6) where p is the truncation to j digits of x in basis \(2k+1\). Thus, \(\Theta (s) < \pi -\epsilon \). Since x is \({\mathcal {C}}_\lambda \)-normal, this happens for a positive proportion of digits, the integral tends to \(-\infty \), and \(\lim _{r\downarrow 0} \frac{\omega (B(x,r))}{r^{d-1}} = 0\). \(\square \)

As a consequence of Proposition 9.7 and the previous claim, we can construct a domain where \(\lim _{r\downarrow 0} \frac{\omega (B(x,r))}{r^{d-1}} = 0\) in a set of dimension s and s can be made as close to 1 as desired. This implies that the non-tangential derivative of a harmonic function (the Green function of the domain) can be 0 in a set of Hausdorff dimension arbitrarily close to 1. Moreover, we can obtain a domain where this set has Hausdorff dimension 1 by concatenating domains of the form \(\Omega _\lambda \) considered before.

10 \({\mathcal {S}}_{\Sigma }(u)={\mathcal {S}}_{\Sigma }'(u)\) in the \(C^{1,{\text {Dini}}}\) case

Recall that for a harmonic function u in a Lipschitz domain that vanishes in a relatively open subset of the boundary \(\Sigma \subset \partial \Omega \), we define

$$\begin{aligned} {\mathcal {S}}_{\Sigma }(u) = \{x \in \Sigma ~|~ |\nabla u(x)| = 0\} \end{aligned}$$

and

$$\begin{aligned} {\mathcal {S}}_{\Sigma }'(u) = \{x \in \Sigma ~|~ u^{-1}(\{0\}) \cap B(x,r)\cap \Omega \ne \varnothing , ~\forall r>0\}. \end{aligned}$$

Remark 10.1

Note that \({\mathcal {S}}_{\Sigma }(u)\) is well defined in the \(C^{1,{\text {Dini}}}\) case since \(u\in C^1({\Omega \cup \Sigma })\) thanks to the results of [9].

The proof of Proposition 1.9 follows from a local expansion of u as the sum of a homogeneous harmonic polynomial and an error term of higher degree (see [22, Theorem 1.1]).

Proof of Proposition 1.9

By [22, Theorem 1.1], for every \(x\in \Sigma \) there exists a positive radius \(R=R(x)\) and a positive integer \(N=N(x)\) such that

$$\begin{aligned} u(y) = P_N(y-x) + \psi (y-x), \quad \text { in } B_R(x)\cap \Omega \end{aligned}$$

where \(P_N\) is a non-trivial homogeneous harmonic polynomial of degree N and the error term \(\psi \) satisfies

$$\begin{aligned} \lim _{y\rightarrow 0} |\psi (y)||y|^{-N} = 0 \quad \text { and }\quad \lim _{y\rightarrow 0} |\nabla \psi (y)||y|^{-N+1} = 0. \end{aligned}$$

We will show that \(N(x) = 1\) implies \(x\notin {\mathcal {S}}_{\Sigma }(u)\) and \(x\notin {\mathcal {S}}_{\Sigma }'(u)\) and that \(N(x)>1\) implies \(x\in {\mathcal {S}}_{\Sigma }(u)\) and \(x\in {\mathcal {S}}_{\Sigma }'(u)\).

Case \(N=1\): We have that \(\nabla u(x) = \nabla P_1(0) + \nabla \psi (0) = \nabla P_1(0) \ne 0\) since \(P_1\) is a non-trivial linear function, thus \(x\notin {\mathcal {S}}_{\Sigma }(u)\). Also, we know that \(u(y) = 0\) for \(y\in \partial \Omega \cap B_R(x)\). Suppose there exist \((z_n)_n\in \Omega \cap B_R(x)\) tending to x such that \(u(z_n) = 0\). Then, by Rolle’s theorem, we get a contradiction since the derivative of u in the direction \(\nabla P_1/|\nabla P_1|\) does not vanish in a neighborhood of x (because \(\lim _{y \rightarrow 0} |\nabla \psi (y)| = 0\)) but u vanishes on \((z_n)_n\) and on \(\partial \Omega \cap B_R(x)\). Thus \(x \notin {\mathcal {S}}_{\Sigma }'(u)\).

Case \(N>1\): Clearly, \(\nabla P_N(0)=0\) if \(N>1\) which implies that \(x\in {\mathcal {S}}_{\Sigma }(u)\). Assume that \(x\notin {\mathcal {S}}_{\Sigma }'(u)\) and, without loss of generality, u is positive near x. Then, by the generalized Hopf principle of [31], we get that \(\partial _\nu u(x) < 0\) contradicting \(x\in {\mathcal {S}}_{\Sigma }(u)\). \(\square \)