Abstract

A topological index is a characteristic value which represents some structural properties of a chemical graph. We study strong double graphs and their generalization to compute Zagreb indices and Zagreb coindices. We provide their explicit computing formulas along with an algorithm to generate and verify the results. We also find the relation between these indices. A 3D graphical representation and graphs are also presented to understand the dynamics of the aforementioned topological indices.

1. Introduction

Chemical graph theory is an important topological field of mathematical chemistry that deals with mathematical modelling of chemical compound structures. A molecular structure of a compound consists of many atoms. Specially, hydrocarbons are chemical compounds which consist of carbon and hydrogen atoms. A graph consisting of hydrocarbons is known as a molecular graph which represents the carbon structure of a molecule [1].

We consider a simple molecular graph, say , which consists of nonhydrogen atoms and covalent bonds. In graph theory, the nonhydrogen atoms are represented by a set of vertices and the covalent bonds with the set of edges . The number of atoms and bonds in a structure is represented by and , respectively. The valency of an atom is represented by , and it is known as the degree of vertex , which also represents the number of adjacent (or neighboring) vertices of . A set consisting of neighboring vertices of is known as open neighborhood and denoted as . If the vertex is included in open neighborhood, then the set of vertices is called closed neighborhood, and it is denoted as .

A double graph is generated by taking two copies of a graph and connecting every vertex in one copy with the opened neighborhood of the corresponding vertex with its second copy. For details, see Figure 1 in which a path graph and its double graph are presented. A strong double graph is generated by taking two copies of a graph and connecting every vertex in one copy with closed neighborhood of the corresponding vertex with its second copy. For details, see Figure 2 in which a strong double graph of and its -iterated strong double graph are presented.

A complement of a graph consists of the same set of vertices, where two vertices and are adjacent by an edge if and only if they are not adjacent in . Hence, . A complement of a graph consists of a number of edges and the degree of vertex which are represented as and , respectively.

A molecular descriptor is known as the topological index provides specific information about the structure of molecules. In graph theory, the molecular structure is considered as a graph . The topological index is also known as the connectivity index [2, 3]. Topological indices are largely applied in chemistry to develop the quantitative structure-activity relationship (QSAR) in which the characteristics of molecules can be correlated with their chemical structures [4]. The physicochemical properties of a molecule can also be explained through topological indices. The first index of a chemical graph was introduced by Harold Wiener [5] in 1947 as an aid to determining the boiling point of the paraffin compound. This index is known as the Wiener index and defined as , where the notation represents the distance between and .

A topological index is defined as a function , where is the set of finite simple graphs and is a set of real numbers which satisfy the relation if is isomorphic to . Recently published work [6, 7] motivated us to further investigate the Zagreb indices and coindices of strong double graphs.

The first Zagreb index and second Zagreb index were introduced by Gutman and Trinajstić in 1972 [8] and elaborated by Nikolić et al. after 30 years in 2003 [9]. and are defined as

The first Zagreb index is also written as .

Recently, some useful versions of Zagreb indices have been discovered, such as multiplicative Zagreb indices [3, 7, 10], multiplicative sum Zagreb indices [11, 12], Zagreb coindices [6], and multiplicative Zagreb coindices [13].

The important variants of the Zagreb index are the first and second Zagreb coindices, which are defined as follows, respectively:

Doslic [14] introduced and in 2008. In 2009, Ashrafi et al. [15] determined the extremal values of these new invariants for some special graphs. They [6] also explored their fundamental properties and provided some explicit formulas for these versions under different graph operations.

2. Main Results

In this section, we study Zagreb indices and Zagreb coindices of strong double graphs. We also study these indices for generalized -iterated strong double graphs. We use the concept of edge partition to reduce computation complexity and obtain computing formulas for these indices.

For the sake of simplicity, we consider and for . Assume that for the sake of consistency.

In the following theorem, we study the first and second Zagreb indices of the strong double graph.

Theorem 1. Let be a simple connected graph of order and size ; then,(i)(ii)

Proof. For the sake of convenience, we label all vertices in as . Suppose that and are the corresponding clone vertices, in strong double graph , of for each .
For any given vertex in and its clone vertices and , there exists by the definition of the strong double graph.
For , if , then , , , and .
So, we only need to consider the total contribution of the following three types of adjacent vertex pairs both to and to .Type 1: the adjacent vertex pairs and , where Type 2: the adjacent vertex pairs for each Type 3: the adjacent vertex pairs and , where The total contribution of adjacent vertex pairs of type 1 in is given byand is given byThe total contribution of adjacent vertex pairs of type 2 in is given byand is given byThe total contribution of adjacent vertex pairs of type 3 in is given byand is given byTherefore, by using equations (3), (5) and (7), we haveBy using (4), (6) and (8), we also haveIn this theorem, we study the first and second Zagreb coindices of the strong double graph.

Theorem 2. Let G be a simple connected graph of order and size ; then,(i)(ii)

Proof. For the sake of convenience, we label all vertices in as . Suppose that and are the corresponding clone vertices, in strong double graph , of for each .
For any given vertex in and its clone vertices and , there exists by the definition of the strong double graph.
For , if , then , , , and .
So, we only need to consider the total contribution of the following two types of nonadjacent vertex pairs both to and to .Type 1: the nonadjacent vertex pairs and , where Type 2: the nonadjacent vertex pairs and , where The total contribution of nonadjacent vertex pairs of type 1 in is given byand is given byThe total contribution of nonadjacent vertex pairs of type 2 in is given byand is given byTherefore, by using equations (11) and (13), we haveBy using equations (12) and (14), we also haveNow, we present the first and second indices and coindices of -iterated strong double graphs.

Theorem 3. Let be a nontrivial graph of order and size , and let be its - iterated strong double graph. Then,(i)(ii)(iii)(iv)

Proof. For any nontrivial graph with vertices and edges, the number of vertices in is and the number of edges in is plus those edges between the sets and , that is, .
Now, we deduce that has vertices and edges.(i).As we know,Using the size of strong double graph , we haveBy Theorem 1 and the definition of the -iterated strong double graph, for , we have(ii).As we know,Using and the number of edges of strong double graph , we haveBy Theorem 1 and the definition of the -iterated strong double graph, for , we have(iii).By Theorem 1 and the definition of the -iterated strong double graph, for , we have(iv).By Theorem 1 and the definition of the -iterated strong double graph, for , we haveand using , we haveBy rearranging the terms, we haveHere, we present an algorithm to generate and verify the first and second Zagreb indices and coindices of any finite simple connected graph . This algorithm is based on the adjacency matrix of (Algorithm 1).

Input:is an adjacency matrix of a finite simple connected graph
Output:,,,
Variables used:=number of rows in,=number of columns in,
(1), , ,
(2)forto
(3)  forto
(4)   sum ofth row of,
(5)   sum ofth column of.
(6)   if
(7)    
(8)    
(9)   end if
(10)   ifand
(11)     
(12)     
(13)   end if
(14)  end for j
(15)end for i

Example 1. Let , , and be the matrices of path graph and strong double graphs and , respectively. These matrices are square and symmetric, and choose value 1 (one) at the th row and th column if and are adjacent vertices in a graph; otherwise, it is 0. The suggested algorithm is applied on these matrices to compute the first Zagreb index , second Zagreb index , first Zagreb coindex , and second Zagreb coindex . These adjacency matrices have been obtained by drawing the respective graphs in “GraphTea” software; this software is easily available, and it is free of cost.The result of the algorithm is given as follows:Now, we provide graphs of Zagreb indices and coindices. Such type of graphical representation will be more helpful to study the dynamics of topological descriptors of the molecular graphs. Here, we present the strong double graph of the path graph, , where and . In Figure 3, the behaviour of the first Zagreb index and second Zagreb index is linear as the straight plane, and the behaviour of the first Zagreb coindex and second Zagreb coindex is nonlinear as the curved form. In Figure 4, we have drawn the curves of these indices and coindices for to understand their dynamics. This figure shows the relation between Zagreb indices and coindices as .

3. Conclusion

We have presented generalized explicit formulas to calculate the first Zagreb index , second Zagreb index , first Zagreb coindex , and second Zagreb coindex of the strong double graph and -iterated strong double graph . The relation between these indices and coindices is also presented as . We have also presented an algorithm with a given adjacency matrix to verify these indices and coindices by programming and numerically. Computer-generated graphs are also given to understand the dynamics of these indices and coindices.

This family of graphs can be considered for other degree-based and distance-related topological indices for further studies.

Data Availability

No data were used to support this study.

Conflicts of Interest

The authors declare that there are no conflicts of interest.

Authors’ Contributions

All authors contributed equally to this work.