On level energy and level characteristic polynomial of rooted trees

Based on the level index, a Wiener-like topological index proposed by Balaji and Mahmoud [ J. Appl. Probab. 54 (2017), 701–709], we deﬁne the level matrix and study the level energy and the level characteristic polynomial of rooted trees. We establish relations between the level matrix and the usual distance matrix. We also determine various bounds on the level energy and calculate the level energy for speciﬁc tree families. Moreover, we provide an explicit expression of the level characteristic polynomial of the so-called rooted double stars and rooted binary caterpillars. Finally, we propose (and provide evidence to support) a conjecture that the rooted path maximises the level energy among all trees with a given number of vertices.


Introduction
The first distance based topological index was introduced by Wiener in 1947 [14].Distances between the vertices of graphs can be showed with a matrix which is called distance matrix.Moreover, the sum of absolute values of the eigenvalues of distance matrix is known as distance energy.Distance energy was introduced by Indulal, Gutman and Vijaykumar, who computed distance energy of graphs having diameter two [8], and several bounds were obtained in [4,7,9,10] thereafter.More details about distance spectra of graphs can be found in the survey [1,5].
Level index, a Wiener-like topological index, was proposed by Balaji and Mahmoud in 2017 for rooted trees [2].The authors introduced the level index for statistical investigations, and used it as a measure of disparity/balance within a rooted tree.
In this paper, we build from the level index by defining level matrix and studying level energy and level characteristic polynomial of rooted trees.We also obtain some relations between the level matrix and the distance matrix of rooted trees.Moreover, we establish bounds on the level energy and calculate the level energy of some classes of rooted trees.Finally, we compute the level characteristic polynomial of so-called rooted binary caterpillars, also known as binary Gutman trees or binary benzenoid trees in chemical graph theory [3].
In Section 2 we introduce some preliminaries about distance matrix of connected graphs and level index of rooted trees.Thereafter, we build the level matrix from the level index and provide basic illustrations.The rest of the paper is devoted to the study of the level energy and level characteristic polynomial.In Subsection 3.1 we establish various bounds on the level energy of rooted trees, while we examine the level characteristic polynomial in specific tree classes such as all rooted versions of stars, so-called rooted double stars and rooted binary caterpillars in Subsection 3.2.Finally, we furnish a conjecture that the rooted path has the maximum level energy among all trees, given the number of vertices, and conclude with some remarks.

Preliminaries
We only consider simple, connected and undirected graphs.A graph G consists of a vertex set V (G) and an edge set E(G).The notation d(u, v) is used to show the distance between two vertices u and v in a graph.

Definition 2.1 ([8]
).Let G be a connected graph and let its vertices be labelled as v 1 , v 2 , ..., v n .The distance matrix of G is defined as the square matrix D = D(G) = [d ij ] where d ij is the distance between vertices v i and v j in G.
Since the distance matrix is symmetric, its eigenvalues are real and can be ordered as Definition 2.4.Let T be a rooted tree and let its vertices be labelled as v 1 , v 2 , ..., v n .The level of v ∈ V (T ) is the distance from the root of T to v. The level matrix of T is defined as the square matrix L = L(T ) = [l ij ] where l ij is the absolute value of the levels' difference of vertices v i and v j in T .Some basic properties of the level matrix are immediate: it is clearly always a symmetric matrix, and the diagonal entries are all equal to 0.

Definition 2.5 ([2]
).The level index of a rooted tree T , denoted by LI(T ), is given by: where l i (T ) shows the level of the vertex v i in T .
The level of a most distant vertex of T is called maximum level and we denote it by l max .We can define the level energy and the level characteristic polynomial as follows.
Definition 2.6.The level energy E L = E L (T ) of a rooted tree T is defined as where λ 1 , λ 2 , . . ., λ n are the L-eigenvalues of T .
For example, consider the tree shown in Figure 1 whose root is the black vertex.The level matrix of T is given as follows: , and the level index of T is computed by Before stating the main theorems of the paper, we also have to report on some important results about distance matrix, distance energy and determinant of block matrices.

Lemma 2.1 ([8]
).Let G be a connected n-vertex graph and let λ 1 , λ 2 , . . ., λ n be its D-eigenvalues.Then 8]).Let G be a connected n-vertex graph and △ be the absolute value of the determinant of the distance matrix D(G).Then

Lemma 2.3 ([9]
).If G is a connected graph with n vertices, then

Main Results
In this section we give several properties of the level energy and compute the level characteristic polynomial of stars, double stars and binary caterpillars.
We also formulate a conjecture on a rooted tree with a prescribed number of vertices that maximises the level energy.To begin with, we first establish further intermediate results that are crucial to proving our main theorems.
By a rooted path, we mean a path whose root is one of the endvertices.The n-vertex rooted path is denoted by P n .
Lemma 3.1.Let T be a rooted tree but not a rooted path.Then det(L(T )) = 0 .
Proof.If T is a rooted path, then there is only one vertex on each level.Therefore, differences between the levels can be computed as distances between the vertices.Thus, we get If T is a rooted tree different from a rooted path, then there are two vertices with the same level.This means that two rows of the matrix L(T ) are identical and we obtain that det(L(T )) = 0.
The Wiener index of a connected graph G is the sum of distances between all unordered pairs of vertices of G. Lemma 3.2 below shows, in particular, that the level index of a tree never exceeds its Wiener index and that the two indices coincide only for the rooted path.
Lemma 3.2.Let T be a rooted tree.The following relation is attained between the entries l ij and d ij of L(T ) and D(T ): Equality holds if and only if vertices v i and v j are on the same path from the root of T .In particular, LI(T ) < W (T ) for T ̸ = P n .
Proof.If vertex v i and vertex v j are on the same path from the root of T , then l ij = |l i (T ) − l j (T )| is precisely the distance between v i and v j .If v i and v j are not on the same path from the root of T , then let u be the last vertex on the common subpath from the root (possibly, u can coincide with the root of T ): in this case, we have Therefore, we get Proof.If v i and v j are in different branches/arms of T , then d ij is computed by sum of the distances from the root to the vertices v i and v j , i.e.
By tr(M ) we mean the trace of a square matrix M .We obtain an analogue of Lemma 2.1 for the level matrix.
Lemma 3.4.Let T be a rooted tree and let λ 1 , λ 2 , . . ., λ n be the L-eigenvalues of T .Then Proof.We have Thus, we get

Bounds on the level energy
In what follows, we consistently assume n > 1.Our first main theorem on the level energy states as follows.
Theorem 3.1.Let T be an n-vertex rooted tree and △ be the absolute value of the determinant of the level matrix L(T ).We have In particular, holds.
Proof.The upper bound can be established by Cauchy-Schwartz inequality together with Lemma 3.4: which is equivalent to The lower bound on the level energy is computed as follows: If T is not a rooted path, then △ = 0 (see Lemma 3.1) and we are done.
If T is a rooted path, then T = P n and L(P n ) = D(P n ) (see the proof of Lemma 3.1).Thus, E L (P n ) = E D (P n ).Furthermore, a result by Graham and Pollack [6] implies ∆ = (n − 1)2 n−2 .By virtue of Lemma 2.2, we conclude that To the best of our knowledge, no one knows a neat formula for E D (P n ), although E D (P n ) ≈ 0.69482n 2 − 0.7964 seems to hold [1].
Our next result shows an inequality between the level energy and the distance energy.
Theorem 3.2.Let T be a rooted tree with n vertices and with maximum level l max .We have Proof.We know an upper bound on level energy from Theorem 3.1 as The difference between the levels of any two vertices of T satisfies with equality if and only if one of the vertices v i and v j is the root and another is the most distant from the root.Thus, we get In the next theorem, we derive another upper bound on the level energy of a rooted tree with n vertices as well as of the rooted path with n vertices.
Theorem 3.3.Let T be a rooted tree on n vertices.We have If equality holds, then T = P n .
Proof.Using Theorem 3.1 and Lemma 3.2, we obtain with the second equality holding only if L(T ) = D(T ), i.e. if T = P n .For the rooted path P n , we have It follows that It is known that the path maximises the distance energy among all trees with a given number of vertices.Since E L (P n ) = E D (P n ), we can formulate the following.
Conjecture 3.1.If T is a rooted tree with n vertices, then

Level characteristic polynomials of some rooted trees
The identity matrix of order n is denoted by I n .By a rooted star, we mean a star whose root is the central vertex.The n-vertex rooted star is denoted by S n .We show in Figure 2 the rooted star with 6 vertices.
Theorem 3.4.The level energy of the rooted star S n is given by: Proof.We obtain the level matrix and the characteristic matrix of the rooted star S n as follows: Since L(S n ) has rank 2, then there are only two nonzero eigenvalues.Moreover, we note that L(S n ) is the same as the adjacency matrix of S n .Therefore, Denote by R n the n-vertex star rooted at one of its non-central vertex, see Figure 3.
Theorem 3.5.The level characteristic polynomial of R n is given by: Proof.We obtain the level matrix and the level characteristic matrix of R n as follows: We can compute the determinant of the characteristic matrix of L(S) by adding minus two times of second row to the first row, giving us .
Next, we compute the determinant with respect to the first row: We notice that the matrix in the first term equals the characteristic matrix of L(S n−1 ).Morover we can substract the second row from all the remaining rows in the matrix of second term.This yields By double rooted star, we mean the tree DS n rooted at vertex v 1 and depicted in Figure 4. Theorem 3.6.The level characteristic polynomial of DS n is given by: Proof.The level matrix of DS n can be given in the following block form: Thus, the level characteristic polynomial of DS n is the determinant of the following matrix in block form: We apply Lemma 2.4 to obtain det(λI 2n − L(DS n )) = det(λA − BB T ) .
On the other hand, we compute that .
In order to compute the determinant of this matrix, we perform some elementary row and column operations.First, we add all the remaining rows to the first row to obtain the following matrix: .
Next, we substract the second column from every other column to obtain the equivalent matrix: .
Next, we expand the determinant with respect to the first row.This gives us: , where each submatrix is of order n − 1.Finally, for each of these submatrices, we add all the remaining rows to the first: Since these two matrices are triangular, we arrive at: This completes the proof of the theorem.
We move our attention to another particular class of rooted trees to which the Gini index was applied in a broader sense, see [2].
Define T m to be the rooted tree depicted in Figure 5, whose root is v 1 .This tree belongs to the family of so-called rooted binary caterpillars [3].Theorem 3.7.For m > 2, the characteristic polynomial of the rooted tree T m is given by Proof.According to Lemma 3.1, we assume that λ ̸ = 0.For every j ∈ {2, 3, . . ., m}, there are precisely two vertices on the same level, namely v j and v j+m .The subtree induced by vertices v 1 , v 2 , . . ., v m+1 is a path rooted at v 1 .Thus the level matrix of T has the following block decomposition: Denote the rows of this matrix (as well as for the identity matrix I 2m ) by R 1 , R 2 , . . ., R 2m in this order, starting from the first to the last.Then R j and R j+m are identical rows of L(T m ) for any j ∈ {2, 3, . . ., m}.Now we substract R j from R j+m in both L(T m ) and I 2m ; so the rows R m+2 , R m+3 , . . ., R 2m in L(T m ) all change to zero rows, and the corresponding rows in respectively.Thus, we have Denote the columns of L(T m ) (as well as for I 2m ) by C 1 , C 2 , . . ., C 2m in this order, starting from the first to the last.Then C j and C j+m are identical rows of L(T m ) for any j ∈ {2, 3, . . ., m}.Now we substract C j from C j+m in the above matrix to obtain the following matrix: , which implies that det xI 2m −L(T m ) is also the determinant of the above block matrix.On the other hand, the product provided that E 4 is invertible.Applying this formula for x ̸ = 0, we obtain: where E is the (m + 1) × (m + 1) matrix defined by .
Furthermore, we can write where .
Moreover, the matrix determinant lemma gives provided that G is an invertible matrix.A generalisation (see [13]) of this formula to the noninvertible matrices states that where adj(G) is the adjugate (transpose of cofactor matrix) of G.In what follows, we use this formula twice.By setting However, adj(G m+1 )u is just the first column of the matrix adj(G m+1 ).Consequently, v T adj(G m+1 )u = 1 2 xg m+1 with g m+1 being the entry in first row and first column of adj(G m+1 ).It follows that We can get a similar expression for det(G m+1 ) by setting This gives us det(G m+1 ) = det(H m+1 + uv T ) = det(H m+1 ) + v T adj(H m+1 )u .
On the other hand, v T adj(H m+1 )u = 1 2 xh m+1 with h m+1 representing the entry in last row and last column of adj(H m+1 ).It follows that det We remark that H m+1 is the characteristic matrix of the distance matrix of the path P m+1 evaluated at 1  2 x.Now we combine equations ( 1) and ( 2) to obtain: for all x ̸ = 0, where C(M ; y) denotes the characteristic polynomial of a matrix M evaluated at y. Fortunately, Hosoya, Murakami and Gotoh [7] computed that Furthermore, we note that the (m + 1, m + 1)-cofactor of H m+1 is also the determinant of the matrix H m , i.e. h m+1 = det(H m ).Similarly, the (1, 1)cofactor of G m+1 is also the determinant of the matrix This completes the proof of the theorem.

Conclusion
There are many open problems concerning the level matrix [2].Some of them are studied in this paper.Naturally, the extremal trees in the set of rooted trees with a given number of vertices deserve to be determined.We have conjectured that the rooted path P n maximises the level energy, which is an analogue of the distance energy result among n-vertex trees.We know that the level energy of P n coincides with its distance energy.Ruzieh and Powers [11] provided in 1990 formulas for all the eigenvalues of the distance matrix of paths.However, these formulas are implicit and can only be approximated.
As for the case of Wiener index, it is not difficult to see that the rooted star (resp.rooted path) uniquely minimises (resp.maximises) the level index among all trees with a prescribed number of vertices.In this paper, we have shown that the Wiener index furnishes a sharp upper bound for the level index.It is natural to ask whether there is a similar lower bound that uses other tree invariants.
Given that we have established the level characteristic of the rooted binary caterpillar as a function of the distance characteristic polynomial of paths, we wonder whether a similar explicit formula can be obtained for the general case where the caterpillar is formed by attaching the central vertex of S n to every vertex of a path, see [2].
On the other hand, in chemistry the electrons of atoms are located on the orbits with respect to their energy levels.Energy levels are related to atomic orbital theory.Therefore, it can be more suitable to find relations between energy levels of electrons and level energy of rooted trees.

Lemma 2 . 4 (
[12]).Let A, B, C, D be square matrices of the same order, andM = A B C D be a block matrix such that CD = DC.Then det(M ) = det(AD − BC)holds.

Lemma 3 . 3 .
since none of the vertices v i and v j coincides with u.Now it is clear that LI(T ) ≤ W (T ) with equality only for the rooted path.Let T be a rooted tree.The following relation is attained between entries l ij and d ij of L(T ) and D(T ):

Figure 4 :
Figure 4: The double rooted star DS n .

Figure 5 :
Figure 5: The rooted binary caterpillar T m .