22institutetext: Department of Futures Studies, University of Kerala, Thiruvananthapuram, India 22email: [email protected]
33institutetext: Indian Institute of Information Technology Kottayam, India 33email: {dhanya,divyaslekha}@iiitkottayam.ac.in
44institutetext: Mathematical Institute, LMU München, Munich, Germany 44email: [email protected]
55institutetext: Indian Statistical Institute, Bengaluru, India 55email: [email protected]
The Median of Sierpiński Triangle Graphs
Abstract
The median of a graph is the set of vertices with a minimum total distance to all other vertices in the graph. In this paper, we determine the median of Sierpiński triangle graphs. Sierpiński triangle graphs, also known as Sierpiński gasket graphs of order are graphs formed by contracting all non-clique edges from the Sierpiński graphs of order ().
Keywords:
Shortest path Median Sierpiński triangle graph.1 Introduction
We deal with many networks in our day-to-day lives. The metric properties of graphs allow us to study the topological features of networks such as social networks, computer networks, and transportation networks in detail [6]. These metric properties help identify important nodes, detect communities, and understand the flow of resources in the network. For example, in social networks, they are used to identify influential individuals or tightly-knit communities.
As a metric property, the median of a graph is significant and finding it makes designing networks much easier [9]. For example, if we can successfully identify the median of a graph in a transportation network then it helps us optimize the placement of various facilities, in such a way, that it minimizes the overall distances as well as makes any facility easily accessible on the network. Similarly, in the case of the spread of diseases, finding medians aids in optimizing the placement of hospitals and clinics for effective resource allocation or deciding vaccination strategies.
The median vertices of a graph are the vertices with the minimum total distance from all other vertices in it. Given a connected (simple) graph with , the distance between two vertices is given by the length of a shortest path between them. The total distance of a vertex is defined as the sum of distances from to all other vertices. Thus, median vertices are vertices that minimise this total distance and form the median of .
Let be a connected (simple) graph with , and with the canonical distance function . The total distance of a vertex is defined as the sum of distances to all other vertices . A median vertex is a vertex that minimizes the total distance over . The eccentricity of is and its average distance is . We then have,
Lemma 1.1.
This is evident, with equalities for complete graphs.
The proximity of G is
and the remoteness of G is
The median is the set of median vertices
Sierpiński triangle graphs are a very common fractal structure that is widely studied and can be found in nature [8]. Recently, Hinz et al. [1] have done a detailed study on the metric properties like center and periphery of Sierpiński triangle graphs. In the present paper, we study the median of Sierpiński triangle graphs.
2 Median of Sierpiński Graphs
Switching Tower of Hanoi (STH) is a variation of the Tower of Hanoi (ToH) game [3]. The goal of STH is to shift the tower of discs from one peg to another. Let us label the discs through , based on their increasing size. The set of rules in ToH apply in STH only for the smallest disc; otherwise we can switch the entire tower of discs 1 through if they lie in order on a single peg, with the disc , if it lies on top of another peg. Therefore, there are moves of type 0 (only disc 1 is moving) and of type 1 (a non-empty subtower and a disc are switched).
We model ToH and STH with discs by Hanoi graphs and Sierpiński graphs , respectively. Any legal distribution of the discs among the pegs, labelled by elements of for convenience, represents a state , where is the peg disc is positioned. Hence and
where and represent the moves to type 0 () and 1 (, respectively. Moreover, we also define the extreme vertices for both and as the vertices corresponding to the states of the ToH, in which all of the discs lie on a single peg. Note that ; see ([3], Figure 4.4).
From [2] we know that with the empty word , and for , such that
For example, we may consider , and we can see and deduce from Figure 1, that .
3 Small Sierpiński Triangle Graphs
Sierpiński triangle graphs are a variation of the Sierpiński graphs. Before delving into how Sierpiński graphs are modified to get Sierpiński triangle graphs, we define primitive vertices of Sierpiński triangle graphs. We define the primitive vertices of as the extreme vertices of , and they are denoted by , where .
In a shortest path between two vertices of , , a non-terminal move of type 0 is always followed immediately by a move of type 1 and vice versa. For the latter there is only one choice, It can therefore be considered as a forced move and left out in an accelerated count of moves. We obtain the Sierpiński triangle graph , , from Sierpiński graph by contracting all edges from . The end vertices and of such an edge in with and and form a combined state , , i.e. vertex in . The extreme vertices , , of are not incident with a move of type 1, so they carry over to primitive vertices of , forming the set . The moves of type 0 in forms the edge set in . In other words, only moves of type 0 in are counted in . More formally,
and , , where iff for some .
Clearly, . Therefore, . By definition of proximity and median, it is trivial that . (Refer to Figure 2.)
Obviously, which comprises the vertices lying on the inner ring, as shown in Figure 2. So .
4 Median of Sierpiński Triangle Graphs
4.0.1 Definitions:
-
1.
is defined as the distance between any two vertices and in the Sierpiński triangle graph .
-
2.
is defined as the distance between any two vertices and in the Sierpiński graph .
-
3.
is defined as the total distance of any vertex from all other vertices in the Sierpiński triangle graph .
-
4.
is defined as the total distance of any vertex from all other vertices in the Sierpiński graph .
-
5.
is defined as the total distance of any vertex from all other vertices except the primitive vertices in the Sierpiński triangle graph .
-
6.
is defined as the total distance of any vertex from all other vertices except the extreme vertices and the vertex that forms a non-clique edge with in the Sierpiński graph .
Our main goal is to find the median of the Sierpiński triangle graphs.
Theorem 4.1.
for all .
The median vertices of are the vertices formed by contracting edges in , whose end vertices are the median of .
M()=:= and for and
.For the proof we need some preliminaries.
Theorem 4.2.
(Equation 6 in Section 3.1 of [1]) For any given vertex , the sum of distances of any given vertex from the primitive vertices is
Theorem 4.3.
(Corollary 4.7 in [3]) For any given vertex , the sum of distances of any given vertex from the extreme vertices is
Theorem 4.4.
For any two given vertices ,
(1) |
Proof.
Let us assume that the shortest path in does not pass through or . We know that in a path, between any two vertices in , clique and non-clique edges occur alternately. The shortest path not passing through and in starts with a clique edge and ends with a clique edge. The shortest in has the same number of edges as the number of clique edges in the shortest path in , that is
(2) |
For the rest of the paths, there are 4 exhaustive cases:
-
Case 1:
The path passes through , the path passes through , and the path passes through both and . (For example, consider the case , , , and in Figure 3, where the shortest path for any pair of vertices follow the red line.)
Therefore, we get:(3) (4) (5)
Combining equations 3, 4, and 5, we get
(6) Figure 3: Sierpiński graph -
Case 2:
The path does not pass through or , the path passes through (or ), and the path passes through (or ). (For example, consider the case , , , and in Figure 4, where the shortest path for each pair of vertices follows the red line.)
Figure 4: Sierpiński graph -
Case 3:
Here, we have subcases, which are similar but different in the way they are represented.
-
(3a)
The path does not pass through or , the path passes through , and the path passes through . (For example, consider the case , , , and in Figure 5, where the shortest path between any pair of vertices follows a path along the red line.)
Therefore, we get:(10) (11) (12) Figure 5: Sierpiński graph -
(3b)
The path does not pass through or , the path passes through , and the path passes through . (For example, consider the case , , , and in Figure 5, where the shortest path between any pair of vertices follows a path along the red line.)
Therefore, we get:(13) (14) (15)
From here on, we will be referring to any pair of vertices and adhering to cases 3a or 3b as Case 3:.
-
(3a)
-
Case 4:
The paths , , and do not encounter the remaining 2 vertices. (For example, consider the case , , , and in Figure 1) Therefore, we get:
(16) (17) (18)
Thus, from these four exhaustive cases, we can safely conclude that equation 1 holds:
∎
Definitions:
-
1.
,
for -
2.
, where
When now consider the distances between any two vertices and , where , and try to find bounds for . The following lemma would be crucial in determining the bounds for .
Lemma 4.5.
, where
Remark 1.
If we consider some , then:
We now look at the distances of all non-median vertices from all other
vertices of the Sierpiński triangle graph .
Lemma 4.6.
If , then for any , we have
Proof.
We start by defining non-clique edges for Sierpiński graphs.
Definition 1.
Non-clique edges in a Sierpiński graphs are those edges which do not belong to a -cycle and which when contracted from the vertices of .
We consider here all non-clique edges in subgraph , whose end vertices are non-median vertices. We extend this result to the rest of the graph by symmetry. We add some value to some , so that is perfectly divisible by 8, that is, =. Before we delve into the proof, we define the concept of parallel edges in Sierpiński graphs.
Definition 2.
In a Sierpiński graph , any two edges and are called parallel edges if , given that , , , and , where and .
- Case A1:
- Case A2:
-
Case A3:
We now consider all edges in of form =, for all . (For example, let us consider , and in Figure 7)
- Case A3a:
-
Case A3b:
Now we consider the edges and , where . All non-clique edges parallel to edges and in subgraphs and , respectively have value as they follow a path similar to Case 3:. There are such edges.
-
Case A3c:
All non-clique edges parallel to edges and in all subgraphs of form and (for all ), respectively have value as they follow a path similar to Case 3:. There are such edges.
- Case A3d:
Total no.of edges with value in Case A3: are:
-
Case A4:
Now we consider all the remaining non-clique edges . All these non-clique edges are parallel to the edge and lie in some subgraph of form or , where . (For example, let us consider and in Figure 7)
-
Case A4a:
All non-clique edges parallel to in all subgraphs of form and , where , have value . (For example, let us consider and in Figure 7) For each of these cases, we have such edges.
-
Case A4b:
Now we consider the edges and , where . If then we consider edge and if then we consider edge . We name our choice of or as and our choice of edge or as .
-
Case A4c:
Moving on, now we consider the graph . We consider the vertex in formed by contracting the edge . Both and can be expressed as and , where and . Next we denote by . Now we consider all subgraphs of that have been formed by contracting non-clique edges of subgraphs of of form , where .
(19) (20) Equating equations 19 and 20, we get . So, we consider the vertex for which lies on the shortest path between and and also, . The edge in that is contracted to form vertex in , also has value . (For example, let us consider and in Figure 7) There are such edges in .
Now we use to represent the set of all the non-clique edges mentioned above in cases ‣ Case A4:, ‣ Case A4:, and ‣ Case A4:.
-
Case A4a:
However, for the first three cases in Lemma 4.6, namely Case A1:, Case A2:, and Case A3:; let us consider E’ to be the set of all aforementioned non-clique edges , where
∎
Theorem 4.7.
, where and
Proof.
This follows directly from the fact that the average distance of the median vertices is less than the average distance of the non-median vertices. ∎

We now try to evaluate about the distance of median vertices from other vertices in the Sierpiński triangle graph .
Lemma 4.8.
If , then for any , we have exactly vertices for which .
Proof.
We will consider the general graph. We consider the edge in the subgraph and the edge and extend it to the rest of the graph by symmetry. For all , we may add some value to so that is perfectly divisible by , that is, =.
-
Case B1:
We consider the edge =. (For example, let us consider and in Figure 7)
- Case B1a:
- Case B1b:
-
Case B1c:
Moving on all non-clique edges in all subgraphs and (for all ) parallel to and , respectively have value as it follows a path similar to Case 3:. For each of these cases, there are such edges.
- Case B1d:
From cases ‣ Case B1:, ‣ Case B1:, ‣ Case B1:, and ‣ Case B1:, we get that total vertices with value are:
All other non-clique edges have value as it follows a path similar to Case 1:.
-
Case B2:
Now we consider the edge =. (For example, let us
consider and in Figure 7)- Case B2a:
- Case B2b:
- Case B2c:
From cases ‣ Case B2:, ‣ Case B2:, and ‣ Case B2:, we get that total vertices with value are:
All other non-clique edges have value as it follows a path similar to Case 1: as we will prove in Theorem 4.9.
Thus, we get that for any , we have exactly vertices for which .
∎
Theorem 4.9.
All non-clique edges other than the ones specified in proof of Lemma 4.8 have value .
Proof.
We consider the non-clique edge in =, where and then we can extend this to the rest of the graph by virtue of symmetry. (For example, let us consider and in Figure 7)
- Case C1:
- Case C2:
-
Case C3:
Next, all non-clique edges not parallel to lines and in subgraphs and , respectively where have value as it follows a path similar to Case 1:.
- Case C4:
All cases Case C1:, Case C2:, Case C3:, and Case C4:, are an exhaustive set of all vertices that are not accounted for in cases Case B1:, and Case B2:.
∎
Theorem 4.10.
For , where and form a non-clique edge, we have , which is formed by contracting the edge , then we get that:
Proof.
We know that, for all x, we may add some value to so that is perfectly divisible by , that is, =. As we have seen that, there are exactly non-clique edges that have value for any choice of non-clique edge , whose end vertices are medians of . Let, us say the set of all the non-clique edges represented by is called .
We use Theorem 4.9 and the already established equation in Lemma 4.8, we get that:
∎
Theorem 4.11.
Let us consider all vertices that are formed by contracting non-clique edges of , whose end vertices belong to . Then, .
Thus, we have proved Theorem 4.1.
References
- [1] Hinz, A. M., Holz auf der Heide, C., Zemljič, S. S., Metric properties of Sierpiński Triangle Graphs, Discrete Applied Mathematics 319 (2022), 439–453.
- [2] Balakrishnan, K., Changat, M., Hinz, A. M., Lekha, D. S., The median of Sierpiński graphs, Discrete Applied Mathematics, 319 (2022), 159–170.
- [3] Hinz, A. M., Klavžar, S., Petr, C., The Tower of Hanoi—Myths and Maths, Second Edition, Springer, Cham, 2018.
- [4] Hinz, A. M., Klavžar, S., Zemljič, S. S., A survey and classification of Sierpiński-type graphs, Discrete Applied Mathematics 217 (2017), 565–600.
- [5] Hinz, A. M., Holz auf der Heide, C., An efficient algorithm to determine all shortest paths in Sierpiński graphs, Discrete Applied Mathematics 177 (2014), 111–120.
- [6] Hernández, J. M., and Mieghem, P. V., Classification of graph metrics, Delft University of Technology: Mekelweg, The Netherlands (2011): 1-20.
- [7] Teguia, A. M., Godbole, A. P., Sierpiński gasket graphs and some of their properties, Australasian Journal of Combinatorics 35 (2006), 181–192.
- [8] Stewart, I., Four encounters with Sierpiński’s gasket, The Mathematical Intelligencer 17, 52–64 (1995).
- [9] Barthelemy, J. P., and Monjardet, B., The median procedure in cluster analysis and social choice theory, Mathematical Social Sciences 1.3 (1981): 235-267.