Abstract
In this study, we first introduce polygonal cylinder and torus using Cartesian products and topologically identifications and then find their Wiener and hyper-Wiener indices using a quick, interesting technique of counting. Our suggested mathematical structures could be of potential interests in representation of computer networks and enhancing lattice hardware security.
1. Introduction
The Wiener index was introduced by Harold Wiener in 1947 as the sum of distances between all pairs of vertices in the molecular graph of an alkane, with the evident aim to provide a measure of the compactness of the respective hydrocarbon molecule [1].
Wiener index has remarkable variety of chemical applications. Wiener himself used it to predict boiling points, molar volumes, refractive indices, and heats of vaporization of alkanes [2–5]. Gutman showed in [6] that the Wiener index measures the area of the surface of the respective molecule and thus reflects its compactness. As a consequence, it is related to intermolecular forces, especially in the case of hydrocarbons where polar groups are absent [7–9]. Wagner proved that every integer greater or equal to 470 is the Wiener index for a class of trees that is connected to partitions of integers [10]. Wand and Yu proved that every integer is the Wiener index of some short caterpillar tree with at most six nonleaf vertices [11]. Hua and Wang gave a new sufficient condition for a connected graph to be traceable by means of Harary index [12]. Hua and Ning gave some tight sufficient conditions for traceability and Hamiltonicity of connected graphs with given minimum degree, in terms of Wiener and Harary indices [13]. Recently, Khalid and Idrees computed the Wiener index of Dutch windmill graph [14], and Thilaga and Sarasija found Wiener index of unitary addition Cayley graphs [15].
Physical and chemical properties of organic substances, which can be expected to depend on the area of the molecular surface and/or on the branching of the molecular carbon-atom skeleton, are usually well correlated with the Wiener index. Among them are the heats of formation, vaporization and atomization, density, boiling point, critical pressure, refractive index, surface tension and viscosity of various, acyclic and cyclic, saturated and unsaturated as well as aromatic hydrocarbon species, velocity of ultra sound in alkanes and alcohols, rate of electroreduction of chlorobenzenes, etc. [16]. Of particular practical importance is the prediction of the behaviour of organic substances in gas chromatography. For instance, chromatographic retention times of monoalkyl- and 0-dialkylbenzenes can be modeled by the Wiener index [17].
Since the pharmacological activity of a substance is related to some of its physico-chemical properties, it is not surprising that attempts have been made to use the Wiener index in designing new drugs [18–20] and hence has a strong impact on stock market. The Wiener index is correlated to cytostatic and antihistaminic activities of certain pharmacologically interesting compounds as well as to their estron-binding affinities [20]. It is also used to study -octanol to water partition coefficient, a physico-chemical parameter of profound importance, for the forecasting of pharmacological activity of many compounds. To learn more about Wiener index, see [21–33].
The hyper-Wiener index was introduced by Randic in 1993 [34]. It is also used to predict physico-chemical properties of organic compounds, particularly to pharmacology, agriculture, and environment protection [35]. In 2008, Khalifeh et al. gave interesting results about the hyper-Wiener index of graph operations [36]. Recently, Raghisa and Nazeran computed the hyper-Wiener index of Dutch windmill graph [14], and Thilaga and Sarasija found the hyper-Wiener index of unitary addition Cayley graphs [15]. For details, see [9, 26, 37–40].
This paper is concerned with the polygonal cylinder and torus and their topological invariants, Wiener and hyper-Wiener indices. First of all, the way we are introducing the polygonal cylinder and torus is unique and useful. Although one can see such a cylinder and torus in literature, precise definitions do not exist. We give precise topological definitions so that one can clearly understand the constructions. Our cylinder depends on two parameters, and , which determine its base and height and hence help further study about it. Similarly, torus is obtained after identifying the ends of the cylinder. Secondly, we computed the indices directly by definition, not by the usual way of recovering them from the Hosoya polynomial. Although the Wiener and hyper-Wiener indices have profound importance because of their strong correlation to various chemical and pharmaceutical properties of chemical compounds, our purpose of computing these indices is the classification of connected graphs. Finally, we hope the cylinder and torus will play a useful role in studying those graphs which contain them as subgraphs. The lattice sheet of the cylinder can be used in enhancing security in semiconductors.
2. Preliminary Notes
A graph is a pair , where is the set of vertices and the set of edges. The edge between two vertices and is denoted by . A path from a vertex to a vertex is a sequence of vertices and edges that starts from and stops at . The number of edges in a path is the length of that path. The distance between two vertices and , denoted by , is the length of the shortest path between them. The diameter of , denoted by , is the longest distance in . A graph is said to be connected if there is a path between any two of its vertices.
Definition 1. A function which assigns to every connected graph a unique number is called a graph invariant. Instead of the function , it is custom to say the number as the invariant. An invariant of a molecular graph which can be used to determine structure-property or structure-activity correlation is called the topological index. A topological index is said to be distance-based if it depends on distances of the vertices of the graph.
In the following, we shall mean by the sum of distances of with all vertices of a connected graph , and we shall mean by the number of pairs of vertices of laying at distance from each other.
Definition 2. (see [1, 41]). The Wiener index of a graph is defined as
Definition 3. (see [34, 41]). The hyper-Wiener index of a graph is defined as
3. Main Results
3.1. Polygonal Cylinder
Definition 4. Consider the Cartesian product of paths , and , with vertices and , respectively. Identify the vertices with the vertices , respectively, and identify the edge with the edge , where . What we receive is the polygonal (actually, ; we may call it -gonal cylinder. You can see in Figure 1.
For brevity, we shall use the symbol ( or simply ) to represent the vertex of . In Figure 2, you can see the grid form of along with simple labels.
P5P4 is shown in Figure 3.
In all the following results, .
A notational digression: by , we shall mean the number of times appears in , and by , we shall mean the number of times appears in .
To avoid repetitions, only the necessary parts of the proofs are given.



Theorem 1. Let be odd. Then, the Wiener and hyper-Wiener indices of the polygonal cylinder are(1)(2)
Proof. In order to count all distinct paths, we need to find distance of each vertex with every other vertex of . For convenience, we shall write lengths of paths in the form of a matrix , which we shall call the distance matrix. corresponding to the polygonal cylinder is symmetric of order . Each row of represents the distances from a vertex to the vertices , respectively. Since we need distinct paths, we shall consider only its upper-triangular part. For this, we represent the upper-triangular part by submatrices. There are distinct submatrices , and . All these submatrices are symmetric, each having order . Each appears times except , which appears times. appears only on the main diagonal of . , appears times in secondary diagonal and times in secondary diagonal. appears only in th secondary diagonal. Thus, the rows of the distance matrix areNow, we give the entries of the submatrices. Since lies on the main diagonal of , only its upper-triangular part contributes towards counting paths and isHowever, all the entries of , contribute towards counting. Since each is symmetric, we give only its upper-triangular part:Now, we count the number of paths in . There are distinct paths; we shall denote the number of paths of length by . Depending on lengths, the paths can be divided into four groups: , , and :Now, :Finally, :12
Example 1. For and , the distance matrix of order is , where the submatrices are , , and . The Wiener and hyper-Wiener indices for odd and for are, respectively, and . The graphs of and are shown in Figure 4.

(a)

(b)
Theorem 2. For even , we have(1)(2)
Proof. The rows of the distance matrix areEach submatrix and appears times. appears only on the main diagonal of . , appears times in secondary diagonal and times in secondary diagonal. These submatrices are the same as in Theorem 1. The paths are divided into three groups: , , and . and are already given in Theorem 1. We need only :
3.2. Polygonal Torus
Definition 5. Consider the Cartesian product of paths , and , with vertices and , respectively. Then, identify, respectively, the vertices with the vertices for and identify, respectively, the edges , with the edges for ; this way we receive a polygonal cylinder. Finally, identify, respectively, the vertices with the vertices for and identify, respectively, the edges with the edges for . What we receive is the polygonal torus . For instance, you can see the construction of in Figures 5–8.
For brevity, we shall use the symbol ( or simply ) to represent the vertex of . In the following, you can see the grid form of with simple labels.
First of all, we identify, respectively, the vertices with the vertices and identify, respectively, edges with the edges for and receive a cylinder.
Finally, after identification of the vertices with the vertices and the edges with the edges for we get the polygonal torus .
In the following, .




Theorem 3. Let and be odd. Then,(1)(2)
Proof. We prove it using the distance matrix corresponding to the polygonal torus , which is symmetric and have order . Each row of represents the distances from a vertex to the vertices , respectively. Since we need distinct paths, we shall consider only its upper-triangular part. For this, we represent the upper-triangular part by submatrices. There are distinct submatrices . All these submatrices are symmetric, each having order . Each appears times except , which appears times. appears only on the main diagonal of . , appears times in secondary diagonal and times in secondary diagonal. appears only in th secondary diagonal.
The rows of areThe rows of , areHere, all entries of each contribute towards counting except , whose only upper-triangular entries contribute. The remaining part of the proof is similar to the proof of Theorem 1.
Theorem 4. Let be odd and be even. Then,(1)(2)
Proof. is the same as in Theorem 3. However, the entries of , are different and are
Theorem 5. Let be even and be odd. Then,(1)(2)
Proof. Here, has order , and there are distinct submatrices and . All these submatrices are symmetric, each having order . Each appears times. appears only on the main diagonal of .