ON THE OPTIMALITY AND DECAY OF p -HARDY WEIGHTS ON GRAPHS

. We construct optimal Hardy weights to subcritical energy functionals h associated with quasilinear Schr¨odinger operators on locally ﬁnite graphs. Here, optimality means that the weight w is the largest possible with respect to a partial ordering, and that the corresponding shifted energy functional h − w is null-critical. Moreover, we show a decay condition of Hardy weights in terms of their integrability with respect to certain integral weights. As an application of the decay condition, we show that null-criticality implies optimality near in-ﬁnity. We also brieﬂy discuss an uncertainty-type principle and a Rellich-type inequality.


Introduction
In a letter to Hardy in 1921, [Lan21], Landau gave a proof of the following inequality for all ϕ ∈ C c (N), ϕ(0) = 0, and p ∈ (1, ∞), where Landau also proved that the constant C p is sharp.This inequality was stated before by Hardy, though hidden in a proof of Hilbert's double series theorem, see [Har20].Therefore, it got the name Hardy inequality with Hardy weight C p • w H p .Recently, in [FKP23], it was shown that C p • w H p can be improved by and thus, the question of finding the 'largest' possible Hardy weight occurs.As a special case of our main result (Theorem 2.3), we show that the Hardy weight w opt p obtained in [FKP23] is optimal and cannot not be improved.We remark that the corresponding classical p-Hardy weight on [0, ∞) is already optimal, see [DP16].The original Hardy inequality was generalised to various contexts.In an abstract way, it can be stated as where E is an energy functional associated with a non-negative operator, and W is the canonically obtained non-negative functional from a positive weight function w.For a detailed analysis, we refer to the monographs [BEL15; KPS17; OK90], and references therein.The aim is now to make w as large as possible with large support, i.e., to make w optimal in a certain sense.This was proposed first in [Agm82,page 6].
In [DFP14], an optimal Hardy weight w associated with a linear Schrödinger operator on domains in R d (or on non-compact Riemannian manifolds) was defined first.Roughly speaking, w is optimal if • w is critical, i.e., for all w w the Hardy inequality fails, • w is null-critical, i.e., the corresponding ground state is not an eigenfunction, and • w is optimal near infinity, i.e., for any λ > 0, the Hardy inequality outside of any compact set fails for the weight (1 + λ)w.
In [DFP14] also a way of obtaining optimal Hardy weights was given.Using a different approach, the main result and definition of optimality of [DFP14] were generalised to p-Laplacians, p ∈ (1, ∞), on Riemannian manifolds in [DP16].Recently, for a large class of potentials (including non-positive potentials), optimal Hardy weights for p-Schrödinger operators were constructed in [Ver23].
On weighted locally finite graphs, inspired by the approaches from [DFP14; DP16], a way of obtaining optimal Hardy weights for linear Schrödinger operators with arbitrary potential parts was given in [KPP18].
In the present paper, we show in Theorem 2.3 how to obtain optimal Hardy weights for p-Schrödinger operators with arbitrary potential term on weighted graphs which are essentially locally finite, following partially the approaches in [DP16; KPP18;Ver23].To be more specific, we evolve discrete quasilinear versions of them, to prove criticality and null-criticality.The main tools in these proofs in [DP16; KPP18; Ver23] were a coarea formula and the ground state representation.Corresponding discrete quasilinear versions of both will also be of fundamental importance here.
For proving optimality near infinity, we establish instead discrete versions of results in [KP20], Theorem 2.5 and Theorem 2.6.Specifically, Theorem 2.5 states a necessary decay condition of Hardy weights in terms of a certain ℓ 1 -summability with respect to weights which are related to positive superharmonic functions.These results are also valid for arbitrary potential parts.
By a supersolution construction technique, we show how to obtain optimal Hardy weights for p-Schrödinger operators.This can be seen as a discrete version of results in [Ver23].The results in the continuum made use of the chain rule, which does not hold on graphs in general.We use instead the mean value theorem to circumvent the problem.
The outline of the present paper is as follows: In Section 2, the basic setting is introduced and the main results are stated.Thereafter, in Section 3, we first prove some convexity-type results which are discrete versions of results in [HPR24; PR15; PP16; PT07] and state the ground state representation formula, confer [Fis23].Then, we turn to the proofs of Theorem 2.5 and Theorem 2.6.In Section 4, we prove a supersolution construction and a coarea formula.Thereafter, we show a proof of Theorem 2.3.In Section 5, we show two applications of the Hardy inequality, the Heiseberg-Pauli-Weyl uncertainty principle and a Rellich-type inequality.We close this paper by discussing briefly some examples.In an appendix, we show that criticality implies the existence of increasing null sequences.

Preliminaries and Main Results
2.1.Graphs and Schrödinger Operators.Let X be a countable infinite set.By a (weighted) graph b on X we understand a symmetric function b : X × X → [0, ∞) with zero diagonal such that b is locally summable, i.e., the vertex degree satisfies deg(x) := y∈X b(x, y) < ∞, x ∈ X.
The elements of X are called vertices and the function b decodes weights between vertices.Two vertices x, y are called connected with respect to the graph b if b(x, y) > 0, in terms x ∼ y.A set V ⊆ X is called connected with respect to b, if for every two vertices x, y ∈ V there are vertices x 0 , . . ., x n ∈ V , such that x = x 0 , y = x n and x i−1 ∼ x i for all i ∈ {1, . . ., n − 1}.For V ⊆ X let ∂V = {y ∈ X \ V : y ∼ z ∈ V } denote the exterior boundary of V .Throughout this paper we will always assume that X is connected with respect to b.A graph b on X is called locally finite if for all x ∈ X # {y ∈ X : y ∼ x} < ∞.
Let S be some arbitrary set, then f : S → R is called non-negative, non-positive, positive, or strictly positive on I ⊆ S, if f ≥ 0, f ≤ 0, f 0, f > 0 on I, respectively.We set f − = (−f )∨0.If for two non-negative functions f 1 , f 2 : S → R there exists a constant C > 0 such that C −1 f 1 ≤ f 2 ≤ Cf 1 on I ⊂ S, we write and call them equivalent on I.
The space of real valued functions on V ⊆ X is denoted by C(V ) and the space of functions with compact support in V is denoted by C c (V ).We consider C(V ) to be a subspace of C(X) by extending the functions of C(V ) by zero on X \ V .
We also introduce the linear difference operator ∇ on C(X) defined via Now, we turn to Schrödinger operators: Let p ≥ 1.For V ⊆ X let the formal space F (V ) := F b,p (V ) be given by We set F := F (X).Note that on locally finite graphs, we have F = C(X).
If V = X we only speak of super-/sub-/harmonic functions.We also need the following definitions: Let V ⊆ X be connected and K ⊆ V be finite.By M(V \ K) ⊆ F (V \ K), we denote the set of strictly positive functions u which are p-harmonic on V \ K, and which have the following minimal growth property: for any finite and connected subset K ⊆ V with K ⊆ K, and any strictly positive function If u ∈ M(V ), then u is called a global minimal positive harmonic function in X, or the Agmon ground state, see [Fis22] for details on these two notions.
If for some fixed vertex o ∈ V a function The double sum part in the definition of h is sometimes called kinetic energy functional and the part of the second sum, potential energy functional.If p = 2 such a functional is a quadratic form, and then sometimes called Schrödinger form.
The connection between H and h on C c (X) can be described via a Green's formula which is stated next, for a proof see [Fis23].
Let V ⊆ X.To shorten notation, we define a weighted bracket . Then all of the following sums converge absolutely and In particular, the formula can be applied to f ∈ C c (X), and Moreover, another nice connection between h and H is that p • H is the Gâteaux derivative of h on C c (X), see [Fis22] for details.
If the functional h is non-negative on on C c (V ).Here, If such a w does not exist, then h is called Remark.This classification of energy functionals in terms of sub-/super-/critical goes back to [Sim80], see also [Mur84;Mur86;Pin88], and is motivated from the analysis of the energy functional h.
In the special case of non-negative potentials and p = 2, a graph is usually called transient if h is subcritical in X, and recurrent otherwise, see e.g.[KLW21].This notation has its origin in probability theory, see e.g.[Woe09], and goes back at least to [Pól21].It is also common when studying Dirichlet forms, see e.g.[FOT11;Stu94], whereas subcritical and critical is used for Schrödinger forms, see [Tak14; Tak16; Tak23; TU23; Miu23; Sch22].In a hand waving way, recurrence means that the associated random walker returns almost surely, and transience means that the random walker escapes any finite set with positive probability.
It is shown in [Fis22], that h is critical if and only if there exists a unique positive superharmonic function (up to multiplies).This function is harmonic and the Agmon ground state of h.
Let h be a critical energy functional.We call h null-critical with respect to the non-negative function w in V if the Agmon ground state is not in ℓ p (V, w), and otherwise we call it positive-critical with respect to w in V .
Here, for all 1 ≤ p < ∞, V ⊆ X and non-negative functions w on V , we define Note that (ℓ p (X, w), • p,w ) is a reflexive Banach space for p ∈ (1, ∞), and a Banach space for p = 1.The focus of this paper is on estimates of functionals.It is therefore comfortable to use the following notation: Any function w ∈ C(X) gives rise to a canonical p-functional w p on C c (X) via The Hardy inequality then reads as h − w p ≥ 0 on C c (X) for some w 0 on X.If it is clear that we mean the functional w p and not the function w, we sometimes simply write w instead of w p .
If not stated otherwise, we will always assume that Moreover, we always explicitly mention the assumption that the underlying graph is locally finite.

Main Results.
We have three main results and in the first two a positive superharmonic function has to satisfy two properties, which are defined next: A is a finite set for any compact set I ⊆ (0, ∞).Note that this definition differs slightly from standard definitions of a proper function as we allow u to vanish infinitely often on V .Moreover, a strictly positive and almost proper function on V is called proper on V .If f is a proper function on V , then 0 and ∞ are the only possible accumulation points of f | V , and if V is also infinite at least one of them is always an accumulation point. Moreover, In particular, such a function cannot vanish on V .
Remark (Locally finiteness).If there exists an almost proper function of bounded oscillation on V ∪ ∂V ⊆ X (where ∂V might be empty), then the graph is locally finite on V .This can be seen as follows: Assume that f is such a function.First note that f > 0 on V ∪ ∂V since f is of bounded oscillation.Then, being proper on V ∪ ∂V implies that 0 or ∞ are the only accumulation points of f | V ∪∂V .Being of bounded oscillation implies that neighbouring vertices never reach an accumulation point.Thus, there exists a compact set in (0, ∞) containing all the images of f | V ∪∂V of neighbours of a vertex and by the properness this implies that any vertex can only have finitely many neighbours, i.e., the graph is locally finite on V .
We also need the definition of an optimal Hardy weight, confer [KPP18] in the discrete (p = 2)-setting and [DP16] in the continuum.
Definition 2.2.The function w 0 is called an optimal (p-)Hardy weight for the energy functional h in V if (i) h − w p is critical in V , (ii) h − w p is null-critical with respect to w in V , (iii) h − w p ≥ λw p fails to hold on C c (V \ K) for all λ > 0 and finite K ⊆ V , i.e., w is optimal near infinity for h.
The first main result tells us now how to find such optimal Hardy weights.The associated version in the continuum is given in [Ver23, Theorem 1.1].Recall that by the Harnack inequality, see [Fis23], a positive superharmonic function is strictly positive.
Theorem 2.3 (Optimal Hardy weights).Let V ⊆ X be non-empty and infinite such that (V, b| V ×V ) is locally finite on V .Let h be a subcritical p-energy functional in V with arbitrary potential c, corresponding p-Schrödinger operator H := H b,c,p,m , and p-Laplacian L := L b,p,m , p > 1.
Suppose that 0 u ∈ F (V ) ∩ C(V ) is a proper function of bounded oscillation on V such that Hu ≥ 0 on V , where H := H b,Cp•c,p,m , and C p := (p/(p − 1)) p−1 .
Furthermore, assume that Lu ∈ ℓ 1 (V, m), u ∈ ℓ p−1 (V, c − ), and (a) u takes its maximum on V , or there exists S > 0 such that for all x ∈ V with u(x) > S we have Lu(x) ≤ 0, and (b) u takes its minimum on V , or there exists I > 0 such that for all x ∈ V with u(x) < I we have Lu(x) ≥ 0.Then, w := H(u (p−1)/p ) u (p−1) 2 /p , multiplied with m is an optimal p-Hardy weight of h on V .
Note that a proper function of bounded oscillation on an infinite graph cannot have both, a maximum and a minimum.
We remark that a sufficient condition for Lu ∈ ℓ 1 (V, m) is Hu ∈ ℓ 1 (V, m) and u ∈ ℓ p−1 (V, |c|) by the triangle inequality.Moreover, if Hu ∈ C c (V ) -in other words, u is p-harmonic outside of a finite set with respect to H, then the conditions Hu ∈ ℓ 1 (X, m), (a) and (b) are satisfied.In [KPP18], where the case p = 2 was investigated, the assumption is that u should be harmonic with respect to H. Hence, in a certain sense the assumptions here generalise the result in [KPP18].Furthermore, if 0 ≤ c ∈ C c (V ), then the conditions u ∈ ℓ p−1 (V, c) and (b) are satisfied.
In addition to that, we remark that in the linear (p = 2)-case no multiplication of the potential with a constant C 2 is needed, see [KPP18].There, a discrete chain rule of the square root was applied which remains unknown for p = 2.However, also for the quasi-linear counterpart in the continuum (that is [Ver23, Theorem 1.1]), the same constant is needed.
As a corollary, we get optimal Hardy weights to Laplace-type operators.The corresponding version in the continuum is given in [DP16, Theorem 1.5].
Corollary 2.4 (Optimal Hardy weights for non-negative potentials).Let V ⊆ X be non-empty and infinite such that (V, b| V ×V ) is locally finite on V , p > 1.Let h be a subcritical p-energy functional in V with non-negative potential c and corresponding p-Schrödinger operator H, and p-Laplacian L. Suppose that 0 u ∈ F (V ) ∩ C(V ) is a proper function of bounded oscillation on V with Hu ≥ 0 on V and Lu ∈ ℓ 1 (V, m) such that (a) u takes its maximum on V , or there exists S > 0 such that for all x ∈ V with u(x) > S we have Lu(x) ≤ 0, and (b) u takes its minimum on V , or there exists I > 0 such that for all x ∈ V with u(x) < I we have Lu(x) ≥ 0.Then, multiplied with m is an optimal p-Hardy weight of h on V .
Note that some explicit examples are given in Section 6.
Remark (Green's functions).It is shown in [Fis22] that whenever h is subcritical in X there exists a Green's function g o : X → (0, ∞) for every o ∈ X with the property that Hg o = 1 o .Thus, g o is a strictly positive superharmonic function that is harmonic outside of a singleton.Hence, Green's functions are natural candidates for the function u in Theorem 2.3 and Corollary 2.4.Also note that there exist graphs associated with subcritical energy functionals whose corresponding Green's functions do not vanish at every boundary point: Take, for instants, the standard line graph N 0 from the introduction with c = 0 and m = 1.On N, this graph is subcritical, and a positive minimal Green's function G 1 on 1 is given by G 1 = 1 on N and G 1 (0) = 0. Note that G 1 is still of bounded oscillation but not proper.Moreover, since LG (p−1)/p 1 = 1 1 on N, the corresponding formula does not result in an optimal p-Hardy weight on N.This shows that the properness seems to be a natural requirement.Another example of a tree with this property is given in [Woe00,p. 240].
Remark (Adding positive potentials).As a consequence of Lemma 4.1, we want to highlight the following: Let b be locally finite on X and W 0. If h admits an optimal Hardy weight w, and h − w has a proper Agmon ground state of bounded oscillation, then w + W is an optimal Hardy weight of h + W .
For example, in order to apply Corollary 2.4, it is sufficient to find a suitable function u when c = ε1 o for some o ∈ X and ε > 0; or if h b,0,p is already subcritical, then one can even set c = 0, which might simplify computations.
The third main result tells us how large a Hardy weight might be in a neighbourhood of infinity.The counterpart in the continuum is [KP20, Theorem 3.1 and Theorem 3.2], and [HPR24, Theorem 7.9].In the following the potential can again be arbitrary.
We set deg W (x) := y∈W b(x, y) for W ⊆ X and x ∈ X.
Theorem 2.5 (Decay of Hardy weights).Let V ⊆ X be connected and non-empty, and h be non-negative on C c (V ).Let W ⊆ V be a non-empty set, and Then for any Hardy weight w on V \ W , we have (b) Assume that h is subcritical in V , and that there are only finitely many edges between V \ K and K. Let v ∈ M(V \ K).Then for any Hardy weight w on V , we have The existence of a Hardy weight on X \ W is ensured by Lemma 3.9.Moreover, the technical assumptions in the preamble of (a) are fulfilled if the subgraph (V, b| V ×V ) is locally finite on finite W . Also note that for any finite K ⊆ X, deg K is a finite measure on X by the local summability condition on b.
The definition of optimality evolved historically, see [DFP14;DP16].It is natural to ask whether there is a connection between optimality near infinity and null-criticality.In the continuum, it is shown in [KP20, Corollary 3.4], that indeed, (ii) implies (iii).Moreover, [DP16, Remark 1.3] states an example that the other implication ((iii) =⇒ (ii)) fails in general.
On graphs associated with linear Schrödinger operators with compactly supported potential part it is shown in [KPP18], that (ii) implies (iii) for a special Hardy weight.
Here, we will show in the following theorem, Theorem 2.6, that (ii) implies (iii) for all p > 1, and all possible potentials if the graph is locally finite and the ground state is smooth enough.It can be interpreted as a corollary of Theorem 2.5, and it includes the case in [KPP18] also for p = 2. See Subsection 3.4 for a proof.
Theorem 2.6 (Null-criticality implies optimality near infinity).Let V ⊆ X be connected and non-empty.Let h − w p be null-critical with respect to w 0 in V with Agmon ground state u in C(V ) ∩ ℓ p (V, b(x, •)) for all x ∈ V , and of bounded oscillation in V .Then w is optimal near infinity for h.[MS23,Lemma 4.1] for the last inclusion.

Decay of Hardy Weights
Here we will prove Theorem 2.5 and Theorem 2.6.Both proofs use certain preliminary results.These are shown in the next two subsections.We start with the ground state representation formula which is also of fundamental importance in the proof of the other main results.Thereafter, we turn to convexity-type results.

Ground State Representation.
Here we recall a recently developed equivalence between the p-energy functional and the so-called simplified energies, see [Fis23] for details.
Let p > 1 and 0 ≤ u ∈ F (V ), V ⊆ X.The simplified energy (functional) h u of h with respect to u on C c (V ) is defined as where we set 0 Theorem 3.1 (Ground state representation, Theorem 3.1 in [Fis23]).Let p > 1, and Furthermore, for p = 2, the equivalence becomes an equality.
Of particular interest is the following special case of the ground state representation: Assume that 0 ≤ u ∈ F is strictly superharmonic, and set w := Hu/u p−1 0, then Theorem 3.1 yields the following Hardy inequality, In the general form of Theorem 3.1, the non-negativity of the left-hand side is also known as Picone's inequality, see [Fis22] for details.Moreover, if u ∈ F is harmonic in X, then we deduce from Theorem 3.1 a second very useful equivalence: From the inequalities in Theorem 3.1, we get as a consequence estimates between the energy associated with the Schrödinger operator and other functionals, which are usually also referred to as simplified energies (see e.g.[DP16;PTT08]).They all are called simplified, because they consist of non-negative terms only, and the difference operator ∇ applies either to u or ϕ but not to the product u • ϕ.
We set on C c (X) and for p ≥ 2, we define on C c (X) and if p ≥ 2, the reversed inequality in (3.2) holds true, i.e., The statements above do not include the case p = 1.This is because a quantification of the strict convexity of the mapping x → |x| p , p > 1, is used in the proofs.
To get optimal Hardy weights, we will use the following observation frequently: Set on C c (X) Then, applying Theorem 3.1, Corollary 3.2, and Hölder's inequality with p ′ = p/2 and q ′ = p/(p − 2), we get the existence of a positive constant C p such that for all 0 ≤ u ∈ F , Moreover, we will often employ some characterisations of criticality from [Fis23;Fis22], which are stated next.
A sequence (e n ) in C c (V ), V ⊆ X, of non-negative functions is called nullsequence in V if there exists o ∈ V and α > 0 such that e n (o) = α and h(e n ) → 0.
Theorem 3.3.Let h be non-negative on C c (V ), where V ⊆ X is connected and non-empty.Then the following statements are equivalent: There exists a unique positive superharmonic function in V (up to linear dependence) and this function is strictly positive and harmonic in V , the so-called Agmon ground state.
Proof.Combine [Fis22, Theorem 2.6] with [Fis23, Theorem 4.1] and the Agmon-Allegretto-Piepenbrink theorem ([Fis22, Theorem 2.3]).This shows in fact the statement for V = X.However, it is not difficult to redo the proof for connected non-empty V X.
Furthermore, we will need that the null-sequence in Theorem 3.3 can be chosen to be increasing.This is shown in Appendix A.
The following result is proven in [Fis22, Corollary 5.6].
Proof.We divide the proof into two steps.
1. Claim: For all non-empty W ⊆ V there exists a strictly positive function Note that the right-hand side is a p-energy functional which we denote by h.Then, clearly, h is non-negative on C c (V ).Moreover, h ≥ (m1 W ) p on C c (V ), i.e., h is subcritical (with p-Hardy weight m1 W ). Since h is subcritical in V such a w exists by Lemma 3.4.2. Claim: Let u be an Agmon ground state of the critical p-energy functional h on V .For every ψ ∈ C c (V ) with u, ψ X = 0, there exists a positive constant C = C(ψ) such that for all finite and non-empty K ⊆ V , we have Assume that the inequality above is wrong.Then there is a sequence Thus, since K is finite and non-empty, there exists o ∈ K and ε > 0 such that for all Thus, e k → C u by Theorem 3.3 for some positive constant C. Since e k , ψ V → C u, ψ V = 0, we have a contradiction, and the second claim is proven.Now, applying both claims yields the result.
We can prove the following convexity-type result.The counterpart in the continuum can be found in [PT07, Proposition 4.3].Proposition 3.6.Let c 0 , c 1 be two potentials such that c 0 = c 1 on a connected and non-empty subset V ⊆ X. Denote the corresponding p-energy functionals by h 0 , h 1 , respectively.Furthermore, define for all t ∈ [0, 1] Proof.The proof follows the ideas from its counterpart in the continuum.Here are the details: Clearly, It remains the case that both h 0 and h 1 are critical in V .Denote by u 0 and u 1 the corresponding Agmon ground states normalised at some o ∈ V .Assume that for some t ∈ (0, 1) also h t is critical.Then by Theorem 3.3, h t has an Agmon ground state u t on V normalised at o ∈ V and a null-sequence (e n ) on V , such that 0 ≤ e n → u t pointwise on V .We show that this results in a contradiction.
We claim that c 0 = c 1 implies that u t cannot be a multiple of u 1 or u 2 .Indeed, let H t be the p-Schrödinger operator associated to h t , t ∈ [0, 1], and assume that , we have by the uniqueness of the Agmon ground state (up to multiplication by a constant) that 1 , i.e., c 0 = c 1 on V .Interchanging the role of u 1 and u 0 yields the claim.
Let (e t n ) be a null sequence for h t converging pointwise to u t , t ∈ [0, 1].Then h t (e t n ) → 0 implies h 1 (e t n ) → 0 and h 0 (e t n ) → 0. Hence, (e t n ) is a null sequence for both h 1 and h 0 .By construction, this sequence converges pointwise to u 1 and u 0 , and also u t .But since c 0 = c 1 , we have that u t cannot be a multiple of u 1 or u 2 , and get a contradiction.Therefore, h t does not admit an Agmon ground state and by Theorem 3.3, it is subcritical in V for t ∈ (0, 1).
A consequence of the previous proposition is given next.For the counterpart in the continuum confer [PT07, Proposition 4.4] or [PP16, Proposition 4.19].
Corollary 3.7.Let V ⊆ X be connected and non-empty, and let h be subcritical in V .Let w ∈ C c (V ) such that w(x) < 0 for some x ∈ V .Then there exists Proof.By Lemma 3.4, there is a strictly positive Hardy weight w associated with h on V .Thus, (w + t • w) p (ϕ) ≤ h(ϕ) + t wp (ϕ) for all ϕ ∈ C c (V ).Since w > 0 on V , and w is of compact support, we get that w + t • w > 0 on V for sufficiently small values of |t|.Let By the previous proposition, Proposition 3.6, S is an interval.Let denote by τ + and τ − , the right and left boundary point of this interval, respectively.
We show that τ − = −∞ can be obtained: Assume that w 0 on V , then wp (ϕ) ≤ 0 for all ϕ ∈ C c (V ), and thus for all t < 0, we get t ∈ S.
We show that h + τ + wp is critical: Clearly, h + τ + wp is non-negative on C c (V ).Assume that h + τ + wp is subcritical, i.e., τ + ∈ S. Arguing as in the beginning, we see that for sufficiently small ε > 0, we get that h + (τ + + ε) wp is subcritical.But this contradicts that τ + is the right boundary point of the interval S.
The following result can be seen as the counterpart of Corollary 3.7 for critical p-energy functionals.Confer [PT07; PP16; PR15] for the local case.
Corollary 3.8.Let V ⊆ X be connected and non-empty, and let h be critical in V with Agmon ground state u ∈ C(V ).
(a) Assume that w ∈ ℓ ∞ (V ) and there exists τ Proof.Ad (a): By Proposition 3.6, h + t • wp is subcritical for all t ∈ (0, τ + ).Thus, we can use Lemma 3.4, and get the existence of a strictly positive p-Hardy weight w associated with the p-energy functional h + t • wp .Let (e n ) be an arbitrary null-sequence of h such that e n → C • u > 0 for some positive constant C, which exists by Theorem 3.3.By Fatou's lemma, we infer Ad (b): The strategy is as follows: If there is τ + ∈ (0, ∞] such that h + τ + • wp is non-negative in C c (X), then by Proposition 3.6, we get that h + t • wp is subcritical for all t ∈ (0, τ + ).
Thus, let us assume that such a τ + ∈ (0, ∞] does not exists.We will show that this leads to a contradiction.Hence, we assume that for all t > 0, there exists By the reversed triangle inequality, h(ϕ t ) ≥ h(|ϕ t |).Thus, we can assume without loss of generality that ϕ t ≥ 0. Since h is non-negative on C c (V ), it follows from (3.6), that wp (ϕ t ) < 0. (3.7) In particular, by Inequality (3.7), we have supp(ϕ t ) ∩ supp( w) = ∅.
Let ψ t := ϕ t / ϕ t p,1 supp w .Then, using that w is bounded on V , we get Since h is non-negative on C c (V ) we obtain using (3.6) and the calculation above, Thus, h(ψ t ) → 0 as t → 0. Since w is finitely supported and since supp(ϕ t ) ∩ supp( w) = ∅ for all t > 0, we have that for some o ∈ supp( w), there exists ε > 0 and a subsequence (ψ tn ) of the net (ψ t ) such that ψ tn (o) ≥ ε, and t n → 0 as n → ∞. Let Hence, (ψ n ) is a null sequence of h, and thus, ψ n → Cu for some positive constant C. By the assumptions on w, we thus have We continue with a simple observation which is basically a consequence of Lemma 3.5.Confer [PT07, Proposition 4.2], or [PP16, Proposition 4.18] for the counterpart in the continuum.
Using a different and more technical method, it is shown in [Fis22, Corollary 4.2] that if h is non-negative on C c (V ∪ {o}) for some V X and o ∈ ∂V then h is subcritical in V .This clearly makes following lemma, Lemma 3.9, redundant.However, for convenience, we give a short argument based on the Poincaré inequality, Lemma 3.5, here.Lemma 3.9.Let W V ⊆ X be both connected and non-empty. (a Proof.If h is subcritical in V , then Lemma 3.4 implies that we have a Hardy weight w which is strictly positive in V .Thus, taking w • 1 W , we have a Hardy weight on W , and h is subcritical in W . Let h be critical in V with Agmon ground state u ∈ C(V ).Take o ∈ V \ W .By Lemma 3.5, there exists a strictly positive function w on V and a positive constant C such that Thus, h is subcritical in W .This proves (a).The second statement (b) is just the contraposition of the first one if h is non-negative on C c (W ).
Proof of Theorem 2.5.Let us mention that there is nothing to prove for W = V or K = V .Hence, in the following, we assume that W V or K V .Ad (a): Let h be critical in V .Then, by Theorem 3.3, there is a null sequence (e n ) in V such that e n → u pointwise, where u ∈ C(V ) is the Agmon ground state of h in V .By Lemma 3.9, we have a p-Hardy weight w on V \ W , i.e., By Fatou's lemma, we have Thus, we have to show that the right-hand side is finite.We calculate, using Theorem 3.1, Moreover, This first sum on the right-hand side can be estimated from above by h u (e n /u).
Since h u (e n /u) ≍ h(e n ) → 0 as n → ∞, we only need to discuss the second sum.
Here we have, using that u satisfies sup x∈W,y∈V \W,x∼y u(x)/u(y) < ∞, the existence of a constant C p > 0 such that We can assume by the result in Appendix A that e n ≤ u.Since we have by assumption u ∈ ℓ p (V \ W, deg W ), we proved (a).
Ad (b): Let h be subcritical in V with corresponding Hardy weight w, i.e., h − w p ≥ 0 on C c (V ).Let v ∈ M(V \ K) for some finite K V .
Using Corollary 3.7, there is a potential w ∈ C c (K) = C(K) such that h − wp is critical in V .Let denote the Agmon ground state on V of h − wp by u.Hence, u ∈ M(V ) ⊆ M(V \K) with respect to h.Furthermore, since u and v are minimal on V \ K and on the finite set K there always exists a constants C > 0 for the strictly positive functions u and v such that u ≤ Cv, we have v ≍ u on V \ K.
Since for all ϕ ∈ C c (V \ K) w is also a Hardy weight for h − wp on C c (V \ K).Thus, we can use the first part, and get that w 3.4.Proof of Theorem 2.6.Here we show, in particular, that if the graph is locally finite and the Agmon ground state is proper and of bounded oscillation, then null-criticality implies optimality near infinity.
Proof of Theorem 2.6.Let u be an Agmon ground state of the critical energy functional h−w p in V .We show the contraposition: Assume that w is not optimal near infinity in V , then there exists µ > 1 and By the assumptions, we can use Theorem 2.5 (a), and get w ∈ ℓ 1 (V, u p ).The latter is equivalent to u ∈ ℓ p (V, w), and therefore, w is not null-critical.

Optimal Hardy Weights
In the following subsections, we will derive optimal Hardy weights for energy functionals with arbitrary potential part.This will be achieved by the virtue of a coarea formula, Proposition 4.7 in Subsection 4.2.Moreover, we will need the technicality that roots of superharmonic functions are also superharmonic.This is discussed in Subsection 4.1.We start proving optimality by showing criticality in Subsection 4.3, and show null-criticality and optimality near infinity in the two succeeding subsections.The proofs of the criticality and null-criticality work mostly along the lines of the proofs of [KPP18] and [DP16;Ver23], by either generalising from p = 2 to p ∈ (1, ∞) or by using discrete non-local versions of local methods in [DP16;Ver23].The proof of the optimality near infinity is instead inspired by results in [KP20], confer also Theorem 2.5 and Theorem 2.6.
But before we start, we note the following discrete version of [Ver23, Lemma 2.35].
Lemma 4.1 (Versano's lemma).Let V ⊆ X be connected and non-empty.Assume that h admits an optimal p-Hardy weight w on V , and h−w p has an Agmon ground state in , also the right-hand side is critical in V with the same ground state u.Moreover, because of (w + ω) p (u) ≥ (1 − ε)w p (u) = ∞, the functional (h + ω p ) − (w + ω) p is null-critical with respect to w + ω.Thus, by Theorem 2.6, w + ω 0 is an optimal p-Hardy weight of h + ω p in V .
Morally, this lemma tells us that sign changing and non-positive potentials are of particular interest.And once, we found a nice optimal Hardy weight for some energy functional, we get a family of optimal Hardy weights by simply adding certain potentials at the weight and the functional.4.1.Supersolution Constructions.One particular crucial step in the proof of Theorem 2.3 will be to show that for a given positive and superharmonic function, certain roots of this function are again superharmonic.It turns out that for positive potentials, this can be deduced from standard techniques, see Proposition 4.5.However, for arbitrary potentials a slightly modified Schrödinger operators has to be considered.This is shown next.In this subsection, we also consider the case p = 1.
Proof.By the mean value theorem, for all z, y ∈ X, there exists ξ Since ϕ ′ ≥ 0, we obtain Moreover, because of −ϕ ′′ ≥ 0, we can estimate as follows This shows (4.1).Ad (a): Using the extra assumption on ϕ and u, and (4.1), we get for all This shows (a).Ad (b): If we add and subtract instead of multiplying the missing potential part, we get using (4.1), By the assumptions on ϕ, u and c, the right-hand side is non-negative.
The last assertion follows from (a) by setting ϕ = (•) 1/q and α = q for some q ≥ 1.
Note that in the case of c ≥ 0 and ϕ = (•) 1/q for some q ≥ 1, it is sufficient to have Hu ≥ 0 on V instead of H b,q p−1 •c,p,m u ≥ 0 on V .
Moreover, a corresponding result for subharmonic functions goes as follows.
be an increasing and convex function, i.e., ϕ ′ , ϕ ′′ ≥ 0. Then for all x ∈ V we have In particular, if u is L-subharmonic on V , then ϕ • u is L-subharmonic on V .
Proof.Mimic the proof of Proposition 4.2.
Next, we want to show a similar result as Proposition 4.2 for a not necessarily differentiable function ϕ.As a downside, we will need to assume that the potential is non-negative.
But first, we start with a result which seems to be true in every quasilinear potential theory.It states that the set of non-negative supersolutions is downwards directed, i.e., it is ∧-stable.Lemma 4.4.Let p ≥ 1, V ⊆ X be connected and let S be a family of functions s ∈ F (V ) which are non-negative on X and Hs ≥ f (s) p−1 on V for some f ∈ C(X).Then, the pointwise infimum u of functions in S is also in F (V ), non-negative on X, and Hu ≥ f (u) p−1 on V .Furthermore, u is either strictly positive or equal to zero on V ∪ ∂V .
Proof.It follows immediately from the definitions that u ∈ C(X) defined via u(x) = inf s∈S s(x) is in F (V ) and non-negative on X.
Let s ∈ S such that s(x) = u(x) + ε for some x ∈ V and ε > 0.Then, for all y ∈ X ∇ x,y u + ε = s(x) − u(y) ≥ ∇ x,y s.
The left-hand side is finite since Thus, we have dominated convergence and can take the limit ε → 0. This results in Hu ≥ f (u) p−1 .We show that u(x) = 0 yields u = 0 in V ∪ ∂V .Indeed, note that which is strictly less than 0 if there exists z ∼ x such that u(z) > 0. But this would give Hu(x) < 0, which is a contradiction by the first part of the proof.Hence, for all z ∼ x we have u(z) = 0.
Next, we show a discrete versions of [HKM06, Theorem 7.5] repectively [BB11, Section 9.8].Note that the following proposition is valid only for non-negative potentials.
In particular, the functions u 1/q , q ≥ 1, are superharmonic on V .
Proof.By the Harnack inequality, see [Fis23], u is strictly positive on V .If ϕ is concave and increasing, then we have the following identity for all t ∈ (0, ∞) Since ϕ ≥ 0, we have β ≥ 0.Moreover, because of c ≥ 0 and u ≥ 0 on V , we get H(αu + β) ≥ 0 on V .Since ϕ • u is the infimum of a set of non-negative superharmonic functions it is by Lemma 4.4 also non-negative and superharmonic.
Remark.We note that in the case of c = 0 on V , the same proof holds for an increasing and convex function ϕ : (0, ∞) → R.Then, in the definition of such a function via supporting lines the number β might be negative.In particular, log u is superharmonic on V with respect to L if u > 0 is superharmonic on V with respect to L.

Coarea Formula.
Here we follow the ideas in [KPP18, Subsection 2.3] (or [KPP20, Lemma 9.3.5])for p = 2 and extend them to p ≥ 1.Additionally, we weaken the assumptions from the linear (p = 2)-case slightly.This generalised coarea formula can also be seen as the discrete analogue of the coarea formula in [Ver23].We will also use the following boundary notation: For V ⊆ X we denote i.e., ∂V contains all directed edges from the interior boundary of V to the exterior boundary ∂V .
Note that a strictly positive proper function on an infinite set cannot take both simultaneously, its maximum and its minimum since either 0 or ∞ is an accumulation point.Moreover, note that on a finite set any strictly positive function on that set is proper.Lemma 4.6 (Stokes-type formula).Let p ≥ 1, and V ⊆ X be non-empty.Let 0 ≤ u ∈ F (V ) be non-constant on V ∪ ∂V and almost proper on X.Let the function g : (inf X u, sup X u) → [0, ∞] be defined via Then, for any t 1 , t 2 ∈ (inf X u, sup X u) such that t 1 ≤ t 2 , the set is finite for any W ⊆ X, and where both sides may take the value +∞.
In the following assume that u = 0 on X \V .Furthermore, in the case of infinite V , assume also Moreover, assume additionally that Lu ∈ ℓ 1 (V, m), and (a) u takes its maximum on V , or there exists S > 0 such that for all x ∈ V with u(x) > S, we have Lu(x) ≤ 0; and (b) u takes its minimum on V , or there exists I > 0 such that for all x ∈ V with u(x) < I, we have Lu(x) ≥ 0.
Then, also g ≍ 1 on X.
Proof.For t > 0, define for any us abbreviate the notation further by writing Since u ∈ F (V ), we can apply Green's formula, Lemma 2.1, which yields Notice that for t 1 ≤ t 2 , both g(t 1 ) and g(t 2 ) share the sum over the set Thus, we conclude together with the observation before, this shows (4.2).
We turn to g > 0: Since u is non-constant and X is connected, ∂X t is non-empty for all t ∈ (inf X u, sup X u), i.e., g > 0 on (inf X u, sup X u).Now assume that u ∈ C(V ), and we show that g < ∞: If V is finite, then u(x) > t only finitely many times and only for By using (4.2), and since V t 1 ,t 2 is finite for all t 1 , t 2 ∈ (inf X u, sup X u), we have g(t 1 ) < ∞ if and only if g(t 2 ) < ∞.Secondly, note that by Inequality (4.3), there are t 1 , t 2 ∈ (inf X u, sup X u) such that t 2 − t 1 > sup x,y∈V,x∼y (u(x) − u(y)).For the choice of these t 1 , t 2 , there is no vertex in Moreover, we observe that for any W ⊆ X, we have (x, y) ∈ ∂W if and only if (y, x) ∈ ∂(X \ W ). Hence, we have by the considerations before and the definition of b u and the assumption u ∈ F (V ) that Next, we show the boundedness of g under certain additional assumptions.The lower bound follows from (a), (b) and (4.2).Here are the details: Indeed, assume it takes its maximum on V , then u −1 ([a, max V u]) is finite for all a > 0 by the almost properness of u.Hence, by (4.2), g changes its value only finitely many times, and thus g ≍ 1 in [a, max V u].A same argument holds, if u takes its minimum instead.If u does not have a maximum, then g might converge to zero as t goes to sup V u = sup X u.By (a) and (4.2), g is increasing in a neighbourhood of sup V u = sup X u, and thus cannot converge to zero.By using (b) instead, a similar argument applies, when u does not have a minimum.
The upper bound follows if we additionally assume that Lu ∈ ℓ 1 (X, m).Then, (4.2) and (a) yields for all t 1 ≤ t 2 with t 2 ≥ S if u does not have a maximum and t 2 = max V u in the other case, The calculation for (b) is similar.
We remark that many of the latter additional assumptions in Lemma 4.6 are satisfied if Lu ∈ C c (X).
Furthermore, if u > 0 on V , then Inequality (4.3) is equivalent to which is satisfied by proper functions of bounded oscillation on infinite V .we prove a formula to translate calculations and estimates of infinite sums over graphs to one dimensional integrals -the so-called coarea formula.This formula will be of fundamental importance in the proof of Theorem 2.3.
where both sides can take the value +∞, and g : (inf X u, sup X u) → [0, ∞] is given by

and (a) u is almost proper and non-constant on
V , (c) u takes its maximum, or there exists S > 0 such that for all x ∈ V with u(x) > S, we have Lu(x) ≤ 0, and (d) u takes its minimum, or there exists I > 0 such that for all x ∈ V with u(x) < I, we have Lu(x) ≥ 0.
Remark.Let u and f be as in Proposition 4.7 with f being continuous, and assume u(x) = u(y) for all x ∼ y with either x ∈ V or y ∈ V .Then, we can use the mean value theorem and get that there is θ x,y ∈ (u(x) ∧ u(y), u(x) ∨ u(y)) such that Thus, the coarea formula can be reformulated as Proof of Proposition 4.7.Let t > 0. As in the previous lemma, Lemma 4.6, we define X t = {x ∈ X : u(x) > t}.Let 1 x,y be the characteristic function of the interval Observe that (x, y) or (y, x) are in ∂X t = X t × X \ X t if and only if t ∈ I x,y .Using this and Tonelli's theorem, we derive This shows the first part of the theorem.The second part follows from Lemma 4.6.
4.3.Criticality.We start with an auxiliary lemma.The lemma introduces a cut-off function which has its origin probably in [PS05] where it was successfully used for the p-Laplacian on R d .In [DP16], it was used to show criticality of p-Schrödinger operators in the continuum, and in [KPP18] the same function was used to show criticality for linear Schrödinger operators on graphs.However, this cut-off function is one particular choice but others are possible as well to prove the following main results, take e.g.partially linear functions.
Let n ∈ N and define the cut-off function Clearly, ψ n ր 1 pointwise as n → ∞.Moreover, we have the following estimate.
Lemma 4.8.Let 0 < β < α < ∞, and ψ n be the cut-off function defined in (4.5), n ∈ N.Then, and there is a positive constant C such that for all q > 1, Proof.The inequalities are clearly satisfied if α ≤ 1/n 2 or β > n 2 , since the lefthand sides and the right-hand sides vanish then.Thus, we can assume in the following that α > 1/n 2 and β ≤ n 2 .Ad (4.6):Firstly, we briefly show that This can easily be obtained by a case analysis.Note that The cases α, β ∈ (0, n] and α, β ∈ [1/n, ∞) can also be obtained from [KPP20].
The remaining cases follow immediately from the formula above.Secondly, we show that Indeed, by the fundamental theorem of calculus, we obtain Using the first two results together with This proves the first inequality.
Ad (4.7):By substituting t = β/α ≤ 1, and since t → (1−t 1/q )/(1−t) is strictly monotonously decreasing as t ≥ 0 increases, we have Moreover, it is not difficult to see that there is a positive constant The key to the above inequality is that the left-hand side is always smaller than 1, and the right-hand side is equivalent to log(n) in the case of α > 1/n 2 and β < n 2 , and to zero elsewhere.In the latter case also the left-hand side vanishes.Using (α − β) ≤ α (and α > 1/n 2 , β < n 2 , 0 < β < α), we derive at This proves the second inequality.
Using the latter lemma and the coarea formula, we will show next that certain p-superharmonic functions will give us weights w such that the resulting p-energy Proposition 4.9 (Criticality).Let V ⊆ X be connected and non-empty such that (V, b| V ×V ) is locally finite on V , and let c be an arbitrary potential.Define H := H b,c,p,m with corresponding subcritical p-energy functional h and p-Laplacian L. Suppose that u ∈ F (V ) ∩ C(V ) is a positive function on V , proper and of bounded oscillation on V with Hu 0 on V , where H := H b,q p−1 •c,p,m , and q := p/(p − 1).Furthermore, assume that Lu ∈ ℓ 1 (V, m), and (a) u takes its maximum on V , or there exists S > 0 such that for all x ∈ V with u(x) > S we have Lu(x) ≤ 0, and (b) u takes its minimum on V , or there exists I > 0 such that for all x ∈ V with u(x) < I we have Lu(x) ≥ 0. Then h − (wm) p is critical in V , where w := H(u 1/q )/u (p−1)/q .Proof.By the Harnack inequality, [Fis23, Lemma 4.4], u > 0 on V .We set v := u 1/q .Because of Proposition 4.2 (a), v is strictly p-superharmonic with respect to H on V .Furthermore, by the definition of w, the function v is a positive p-harmonic function with respect to H − w in X, i.e., Hv = wv p−1 on V .
The strategy of the proof is to construct a null-sequence on V with respect to h − (wm) p which converges pointwise to u.By Theorem 3.3, this then implies that h − (wm) p is critical on V .
We take the cut-off function ψ n : [0, ∞) → [0, 1] defined in (4.5) and set e n ∈ C(V ) via If V is finite then, clearly e n ∈ C c (V ).If V is infinite, we also have e n ∈ C c (V ), since supp(ψ n ) ⊆ (0, ∞), and sup V u = ∞ or inf V u = 0 by the properness assumption on u.Obviously, e n ր 1 pointwise on V as n → ∞.So, we are left to show (h − (wm) p )(ve n ) → 0 as n → ∞.
Using (3.5), we get for some positive constant C p , We will show that the right-hand sides vanish as n → ∞.We compute where | p dt whenever the denominator does not vanish and a n (x, y) = 0 otherwise.
Using (4.6), we obtain (assuming without loss of generality that u(x) ≥ u(y), otherwise we use a symmetry argument) since u is of bounded oscillation on V .We use this estimate and apply the coarea formula with f (t) = t p−1 |ψ ′ n (t)| p .Note that the assumptions of the corresponding proposition, Proposition 4.7, are fulfilled.Therefore, there exist positive constants C 1 and C 2 such that for all n ∈ N The term on the right-hand side tends to 0 as n → ∞.Thus, for 1 < p ≤ 2, (ve n ) is indeed a null-sequence for (h − (wm) p ) v , which implies by the ground state representation formula the criticality of the functional h − w p .We are left to analyse the case p ≥ 2.Here we calculate Using (4.7) with q = p/(p − 1), we obtain (assuming without loss of generality that u(x) ≥ u(y), otherwise we use a symmetry argument) that there is a positive constant C 3 such that ãn (x, y) Then, we can use again the coarea formula but this time with f (t) = t −1 |ψ n (t)| p .Thus, there exist positive constants C 2 , C 3 , C 4 such that This shows the statement.
4.4.Null-criticality.In the present subsection we prove the null-criticality of h − w p for a specific w under some familiar constraints, confer [KPP18] for p = 2.We need the following elementary inequality.

Because of log
Moreover, substituting t = β/α ≤ 1 yields Let g(t) = (1 − t 1/q )/(1 − t).Then it is easy to see that g is strictly monotonously decreasing for all t ≥ 0.Moreover, by L'Hôpital's rule it follows that min Combining this with the inequalities before yields the result.Now we can show the main result of this subsection.
Proposition 4.11 (Null-criticality).Let V ⊆ X be connected, non-empty and infinite such that (V, b| V ×V ) is locally finite on V .Define H := H b,c,p,m with corresponding subcritical p-energy functional h and p-Laplacian L. Suppose that 0 u ∈ F (V )∩C(V ) is a proper function of bounded oscillation in V with Hu ≥ 0 on V , where H := H b,q p−1 •c,p,m and q := p/(p − 1).Furthermore, assume that we have Lu ∈ ℓ 1 (V, m), u ∈ ℓ p−1 (V, c − ), and (a) u takes its maximum on V , or there exists S > 0 such that for all x ∈ V with u(x) > S we have Lu(x) ≤ 0, and (b) u takes its minimum on V , or there exists I > 0 such that for all x ∈ V with u(x) < I we have Lu(x) ≥ 0.Then, the p-energy functional h − (wm) p with w := H(u 1/q )/(u (p−1)/q ), is nullcritical in V with respect to wm.
Proof.By Proposition 4.9, we know that h − (wm) p is critical on V with Agmon ground state u 1/q .We have to show that (wm) p (u 1/q ) = ∞.
If c(x) ≥ 0 for some x ∈ V , then the potential part at x of the p-energy functional can be bounded from below by 0. Because of u ∈ ℓ p−1 (V, c − ) and 0 ≤ e 1/q n ≤ u 1/q , the potential of the negative part of c remains finite for all n ∈ N. Altogether, we only have to consider the divergence part.Denote K n := supp e n ∈ C c (V ).We have Otherwise, we estimate a by 0 from below.Since K n is finite, e n is almost proper on V , and non-constant on K n ∪ ∂K n .We apply the coarea formula (Proposition 4.7) with f (t) = 1/t.Thus, we get x,y∈Kn∪∂Kn b(x, y)(∇ x,y e 1/q n ) p = x,y∈Kn∪∂Kn b(x, y)a(x, y) (∇ x,y e n ) p−1 en(x) en(y) where Cn is a positive constant.Since u is of bounded oscillation, lim n→∞ Cn ∈ (0, ∞).By the properness of u and since V is infinite, we have that 0 or ∞ are accumulation points of u in V , and therefore Consequently, (wm) p (u 1/q ) = ∞.4.5.Optimality Near Infinity.Here, we finally prove Theorem 2.3.Because of Proposition 4.9 and Proposition 4.11, we are only left to show the optimality near infinity.This, however, is a consequence of Theorem 2.6.
Proof of Theorem 2.3.Proposition 4.9 and Proposition 4.11 imply that the function w := H(u 1/q )/u (p−1)/q , q := p/(p − 1), multiplied with m is a p-Hardy weight such that h − (wm) p is null-critical with Agmon ground state u 1/q .Furthermore, since u is proper and of bounded oscillation, also u 1/q is it.Thus, we can apply Theorem 2.6 and get that wm is indeed an optimal p-Hardy weight.

Applications
Here, we briefly discuss two applications of the Hardy inequality, an uncertaintytype principle and a Rellich-type inequality.
5.1.Heisenberg-Pauli-Weyl-type Inequality.The famous Heisenberg-Pauli-Weyl uncertainty principle is a direct consequence of the Hardy inequality.It asserts, roughly speaking, that the position and momentum of a particle can not be determined simultaneously.For further information confer e.g.[BEL15, Subsection 1.6] for a detailed discussion in the Euclidean space, [KO09; KO13; Kri18] for Riemannian manifolds, or [Ber+20, Section 3] for a recent version in the hyperbolic space.
Assume that h is subcritical in X with Hardy weight w.Then by the Hölder and Hardy inequality, we derive for all ϕ ∈ C c (supp(w)) This is a quasilinear version of the Heisenberg-Pauli-Weyl inequality on graphs.
For the special case of the line graph on X = N 0 discussed in the introduction, we thus obtain by taking the optimal Hardy weight , where the second inequality follows from the comparison with the classical Hardy weight w for details.

Rellich-type Inequality.
Another inequality which has attracted a lot of attention is the Rellich inequality.For more details on the history and generalisations of this inequality in different settings, we suggest the papers [Ber+20; KPP21; KO09; KO13] and the monograph [BEL15], and references therein.
Assume that h is subcritical in X with strictly positive Hardy weight w.Then by the Hardy inequality, Green's formula (Lemma 2.1), and the Hölder inequality, we obtain for all ϕ ∈ C c (supp(w)) This implies the Rellich-type inequality We have to admit that classical Rellich inequalities have different powers of the Hardy weight on both sides of the equation.This, however, needs more effort.
For the special case of the line graph on X = N 0 discussed in the introduction, we obtain by taking the classical Hardy weight w H p , and optimal Hardy weight w opt p from the previous subsection,

Examples
Here we discuss briefly some prominent examples of graphs: the natural numbers, homogeneous trees, model graphs and the Euclidean lattice.Thereafter, we give an example of a non-locally finite graph, where the formula from Theorem 2.3 does not result in an optimal Hardy weight.Example 6.1 (N).By Corollary 2.4, we see that the p-Hardy weight on N obtained in [FKP23] and stated in the introduction is not only an improvement of the original Hardy weight but also optimal.By Versano's lemma, Lemma 4.1, we also get optimal p-Hardy weights for a large class of Schrödinger operators on N. It is not difficult to see that the Green's function G o is given by G o (r) = C p • d −r/(p−1) , r ≥ 0 for some constant C p > 0. The Green's function G o is proper and of bounded oscillation.Obviously, also the remaining conditions in Corollary 2.4 are fulfilled.Hence, an optimal p-Hardy weight is given by Note that for p = 2, this is the result obtained in [BSV21, Eq. (1.3)].Moreover, this optimal weight is constant for r ≥ 1 and does not converge to zero.In the case of p = 2, w(r) for r ≥ 1 is exactly the bottom of the ℓ 2 -spectrum of the free Laplacian on T d+1 .
Real hyperbolic spaces H(R d ) are often considered to be a counterpart in the continuum to homogeneous trees.Here, similar results were obtained, see [Ber+17; BGG17] (or for the closely connected Damek-Ricci spaces see [FP23]).However, using the analogue method from [DP16], one can show that the weight in the continuum is larger than a similar positive constant and converges exponentially fast to it.Hence, this is somehow the reversed observation than between N and (0, ∞).
The calculation on T d+1 can be generalised easily to all subcritical model graphs.This is done next.Example 6.3 (Model graphs).We need some notation first: The function d : X × X → [0, ∞) be the combinatorial graph distance, that is, its value is the least number of edges of a path connecting two given vertices.Moreover, for some fixed vertex o ∈ X we set Let us fix o ∈ X.A graph b on X with potential c is called model graph with respect to o if k ± and c/m are spherically symmetric functions, i.e., k ± (x) = k ± (y) and c(x)/m(x) = c(y)/m(y) for all x, y ∈ S r (o) and all r ≥ 0. The p-Laplacian of spherically symmetric function f = f (r) is given by If the Green's function to the free p-Laplacian on a locally finite model graph exists, it is given by If this is the case, Corollary 2.4 can be applied.Setting g = G (p−1)/p o , we calculate Hence, wm is an optimal p-Hardy weight.Thus, an optimal p-Hardy weight is given by w := Lu (p−1)/p /u (p−1) 2 /p , 1 < p < d.
A downside of the main result of this chapter is that it is restricted to essentially locally finite graphs.It is natural to ask if the formula also yields optimal weights in beyond that setting.Next, we shown an example that this not the case if the formula in Theorem 2.3 is used with Green's functions on star graphs.Example 6.5 (Star graphs).Even though, we cannot apply Theorem 2.3 on a star graph, we can calculate the formula and check by hand if it satisfies all desired properties.
A star graph on X = N 0 with root 0 is a locally summable graph such that b(0, n) > 0 for all n ∈ N, and b(m, n) = 0 for all m, n ∈ N, i.e., every vertex is only connected to the root 0. Let us add any potential c such that h is subcritical (e.g.take a positive potential c 0).Let G 0 denote the minimal positive Green's function with HG 0 = 1 0 .Note that HG 0 = 0 and G 0 > 0 on N implies Clearly, w > 0 on N. Note that this defines also the value at 0 implicitly.The natural candidate for a ground state of h − (wm) p is u = G Let us assume that c 0. By Equation (6.1), we get that u(0) ≥ u(k) for all k ∈ N.Moreover, by the local summability of the graph, we get Since 1 − (1 − u(k)/u(0)) p−1 ≥ 0, we can use the theorem of dominated convergence, and get (h − (wm) p )(e n ) → 0 as n → ∞.Hence, h − (wm) p is critical with Agmon ground state u.
Let us turn to the null-criticality: if we show that u ∈ ℓ p (N 0 , wm), then h−(wm) p is null-critical with respect to wm.Since e n ր u, we have (wm) p (e n ) ր (wm) p (u).Since (e n ) is a null sequence of h − (wm) p , it suffices to have a look at h(e n ).Here, Since G 0 ∈ F b,p we get from Hölder's inequality and the local summability of the graph that u ∈ F b,p+1 , which implies that the first sum remains finite as n → ∞.Furthermore, since the graph is locally summable the second sum stays finite.Because of HG 0 = 1 0 on N 0 , we have Hence, the third sum in (6.2) converges monotonously to m(0) + c(0)G p−1 0 (0) ∈ (0, ∞).Hence, u ∈ ℓ p (N 0 , wm), and the corresponding functional is positivecritical.
Therefore, the formula of Theorem 2.3 applied to a Green's function on a star graph does not result in an optimal weight.

Appendix A. Criticality Implies Increasing Null-Sequences
Here we show that criticality implies the existence of an increasing null sequence.There is nothing to prove for V being a singleton.Denote by u the Agmon ground state on V .Take an arbitrary increasing exhaustion (K n ) of V with finite, non-empty and connected sets, and some o ∈ K 1 .Without loss of generality, we can assume that u(o) = 1.
Let H n be the p-Schrödinger operator we obtain by adding m/n to the potential c of H, n ∈ N, with p-energy functional h n .Then, for all n ∈ N, By the maximum principle, [Fis22, Proposition 3.10], we get the existence of a sequence (v n ) in C(K n ) such that H n v n = g n on K n for any 0 ≤ g n ∈ C(K n ).Assume that 0 g n → g pointwise.Then, again by [Fis22, Proposition 3.10], v n > 0 on K n .
If v n (o) → 0 as n → ∞, then by the Harnack inequality, [Fis23, Lemma 4.4], v n → 0 on V which is a contradiction unless g = 0.However, 0 is not a positive function.This motivates to consider w n := v n /v n (o) and gn := g n /v p−1 n (o) instead.Let us set o (K n 0 , H n 0 ) for any n ≥ n 0 ∈ N.This implies by the Harnack inequality also that w n cannot converge to ∞.Thus, by the Harnack principle, [Fis22, Lemma 3.2], (w n ) converges pointwise to some w ∈ S + o (K n 0 , H n 0 ) for all n 0 ∈ N, and 0 ≤ H n 0 w(x) = Hw(x) + w p−1 (x)/n 0 for all x ∈ K n 0 .Letting n 0 → ∞, we see that the limit w is positive and p-superharmonic on V .By Theorem 3.3, this is a contradiction unless w = u.Note that this implies the convergence of (g n ) to 0. Our first candidate of an increasing null-sequence is (w n ).Let us try to apply the weak comparison principle, [Fis22, Proposition 5.3].Obviously, w n ≤ w k on X \ K n , and k ≥ n.Moreover, for all x ∈ K n , and k ≥ n, Because of w k ∈ S + o (K n , H n ), let us now choose the specific function g n = 1 o .By the weak comparison principle, (v n ) is increasing, by the first part, it converges pointwise to ∞.Then, there is a subsequence (g n k ) such that for all Thus, (w n k ) is increasing by the weak comparison principle.By construction, 0 ≤ g n k w n k → 0 • u = 0 pointwise on V .Hence, there is a decreasing sub-subsequence (g n k l w n k l ).Thus, we conclude with the aid of Green's formula and monotone convergence, Hence, we have an increasing null sequence.
y) ≤ C p x∈W,y∈V \W b(x, y)e p n (y) = C p y∈V \W e p n (y) deg W (y).
x,y∈X b(x, y) ∇ x,y e 1/q n p =x,y∈Kn∪∂Kn b(x, y) ∇ x,y e 1/q n p .By Lemma 4.10, we have whenever e n (x) = e n (y) for x ∈ K n with x ∼ y a(x, y) := ∇ x,y e 1/q n p |∇ x,y e n | p−2 (∇ x,y e n )

On
R d , p = d, with the free p-Laplacian, the classical Hardy weight W (x) = (p − 1/p) p |x| −p is an optimal p-Hardy weight on R d \ {0}, see [DP16, p. 4] which follows by taking simply the Green's function on R d as reference function.Hence, for d = 1, we have an significant difference between the continuous and discrete model in terms of the p-Hardy weights.The optimal p-Hardy weight on (0, ∞) is only the first term of the Taylor expansion of the optimal p-Hardy weight on N. Example 6.2 (T d+1 , d ≥ 2).A homogeneous regular tree T d+1 is a connected tree such that every vertex has d + 1 neighbours, d ≥ 2. If x and y are neighbours then b(x, y) = 1.Moreover, we set m = 1 and c = 0, and fix the root o ∈ T d+1 .