1. Introduction
The term Internet of Things (IoT) has been known for the last few years. IoT describes a vision where every object becomes a part of the Internet, and has been recognized as one of the major technological revolutions of this century [
1,
2].
IoT allows things and people to be connected anytime, from anyplace, with anything and anyone, preferably using any network/path and any service [
3]. The fundamental goal is to create a more desirable world for human beings, where objects and things around them know what they want, what they like, and what they need and act accordingly without any explicit instructions [
4]. The outspread use of IoT in various domains, such as transportation [
5,
6,
7], health [
8,
9,
10], manufacturing [
11,
12,
13], and other fields aims to create a new environment of applications which will influence our lives [
14,
15].
The search for a specific service is a crucial challenge such as battery energy, interoperability, reliability, scalability, availability, etc. Moreover, network lifetime is the total amount of time to maintain its full functionality [
16], it is constrained by the battery of nodes [
17]. These constraints that are related to the nature of a node and are named as the “
Capability” of the node. A capability indicates the capacity to perform a particular service, task, activity, or function [
18,
19,
20].
Due to the rapid technology and development that are happening in our social lives, a new concept named Social Internet of Things (SIoT) has been proposed [
21,
22]. It is an integration of social network and Internet of Things, introducing a new vision of social relationships among different devices/things, independently from the fact that they belong to the same or to different platforms owned and managed by different organizations. This vision makes all the IoT devices ready to cooperate with others and create relationships among them as human beings do. According to the growth of intelligent devices especially in smart cities, the social Internet of Things offers a new mechanism of communication among nodes, in a distributed manner, with only local information. This mechanism allows the nodes to search for services and resources by themselves instead of the central systems such as servers, cloud computing, etc.
Figure 1a illustrates the concept of SIoT, there are two entities: object and service. These entities can provide and consume services and/or data. In this sense, services themselves can consume data produced by other services to form a composite service or to be used for other objectives.
Figure 1b shows a mechanism of service search in SIoT, where the communication is in a decentralized manner. When a node receives a request that includes the requirements of a customer node, it verifies if it can respond to this request by itself or by its friends, elsewhere it will be transmitted to a given node until the provider node is found. The similarity between the request requirements and service is divided into two types that are proximity and point. The point type is the provider node should respond strictly to the declared requirements such as monitoring the temperature at a fixed location, while in the proximity type is the provider node could respond flexibly to the declared requirements such as monitoring the temperature at a specific area.
According to [
23], there are five types of friendship in the SIoT, namely:
Parental Object Relationship (POR): It is established among similar objects. They have the same producer, model, and production batch.
Co-location Object Relationship (C-LOR): It is established among heterogeneous or homogenous objects that share the same location.
Ownership Object Relationship (OOR): It is established if the objects are owned by the same user.
Co-work Object Relationship (CWOR): It is established when two or more devices collaborate to accomplish a common goal.
Social Object Relationship (SOR): It is established if there is a liaison between the objects.
In SIoT every node will be able to search for the desired service using its friends. As a node can be surrounded by many nodes, selecting a set of friends from the neighboring nodes is an essential phase, which affects the service search task. The efficiency of Friendship selection strategies is often measured in terms of the parameters of network navigability: giant component, average path length, average local clustering coefficient, average degree, and diameter of the network. The enhancement of these parameters boosts rapid search for the service but does not guarantee it.
Furthermore, each node must manage the selected friends, such that the selection of many friends affects negatively the capacity of storage, battery power, etc. So, it is desirable to limit the number of friendships for each node. On another side, during the service search, the nodes lose their energy which leads to reduce network lifetime; therefore, the customer nodes can be unable to obtain the requested services. The research question is how to create efficient strategies that improve the parameters of network navigability and increase the network lifetime, also to propose a new mechanism to speed up more the service search process.
The objective is to create a new approach for the fastest, dynamic, and autonomous service search among nodes in SIoT by considering the capacities of different devices in SIoT. Furthermore, the current work can provide many benefits for practitioners and researchers who want to develop or integrate IoT applications that can exploit the services provided by the systems of smart healthcare, smart agriculture, smart city, etc. Moreover, it is designed to support the 5th generation (5G) that is required to quickly and efficiently respond to complex IoT requests.
To overcome the limitations associated with SIoT, we propose a new approach with features described as follows.
Firstly, we create the node groups, where each group has only one master node, and these groups run a consensus algorithm to agree on a specific value.
Secondly, we create a new friendship selection strategy using groups of nodes based on an agreed value and other properties. The social network is built to achieve a better navigability and to be a suitable network for minimizing the number of hops and balancing the resources.
Thirdly, a node sorts and resorts all the friendships based on the capabilities of nodes, groups, their centrality, and popularity, in order to speed up the search task and increase the network lifetime.
The performance of our contribution has been analyzed in terms of giant component, average degree, average local clustering coefficient, average path length, network diameter, number of hops to achieve the providers, and network lifetime.
The remainder of this paper is organized as follows:
Section 2 introduces the related works,
Section 3 includes the problem definition and parameters of a network,
Section 4 presents our proposed contribution,
Section 5 gives simulation results and discussion, and the final section concludes the paper.
2. Related Works
The social networks’ navigability improvement is equivalent to the achievement of the following criteria, stated simultaneously: maximizing the giant component and local clustering coefficient, and minimizing the average degree, the average path length and the diameter.
In [
24], the authors presented five strategies to select the friendships in a network. At first, a node accepts all the friendship requests until it reaches the maximum number of allowed connections. Then, to manage any further requests, one of the following strategies is proposed to select the new friendships:
Strategy 1: A node accepts any new request of friendship.
Strategy 2: A node accepts requests of nodes that have a greater number of connections (decreasing order).
Strategy 3: A node accepts requests of nodes that have a fewer number of connections (increasing order).
Strategy 4: A node accepts requests of nodes that have a greater number of common connections.
Strategy 5: A node accepts requests of nodes that have a fewer number of common connections.
These five strategies are applied separately to create the social network. The results show that strategies 3 and 5 achieve the total giant component of nodes, strategies 2 and 5 have a low average path length, strategies 2 and 4 have the lowest average degrees, and strategies 1 and 4 have a high value of local clustering coefficient.
The algorithm in [
25] based on the strategies presented in [
24] applies the genetic algorithm for friendship selection in IoT. The algorithm is used to maximize the number of friends (strategy 2) and friends of friends (common friends) (strategy 4) simultaneously, for selecting the optimal near node i.e., reaching the destinations rapidly. The results achieve an enhancement in the shortest path length, and also an acceptable average degree and average local clustering coefficient values in comparison with the work presented in [
24].
A heuristic method is proposed in [
26] to select friends in the SIoT, based on reachability and type of relationship properties. When a node achieves the maximal number of friends and there is another node that sends a friend request, it checks the ability of its friends and the candidate friend to achieve their destinations, by calculating the reachability factor and verifying the relationship type. Based on these two factors, the node decides to add or to reject the candidate friend. This heuristic method improves the average degree and average path length, but the giant component is modest (52%).
Authors in [
27] proposed an algorithm to resolve the link selection (friends selection) issue in SIoT, by restricting the number of connections for each node using a threshold value in order to improve the properties of navigability: path length, average clustering coefficient, and giant component. The threshold value is adjusted dynamically based on the number of hubs in network, which allows to add new friends and to remove old mutual friends. The experimental results show higher average clustering coefficient, shorten path length, and higher giant component. The enhancement of the properties of navigability makes service discovery task faster.
To decrease the path length from a requestor node to a provider node, authors in [
28] proposed two mechanisms:
A caching system: The nodes store pieces of information such as a document, web page or video. The storage location is based on the requestors of these services: the more these services are requested, the closer they are to the node’s storage location.
Friendship selection: Established when a node creates new paths of friendship to decrease the path length to the provider node and removes friends that do not belong to the shortest path.
The results show that the caching system strategy has a less than average hop length than the friendship selection strategy but it is expensive in terms of memory consumption.
To overcome the issues of the search/discovery phase in SIoT, the authors in [
29] proposed an algorithm to select a friend that can receive/execute the requested services using a combination of two properties. The first property is the centrality (the degree) of a friend; a friend (intermediate node) with a high centrality is selected to receive the requested service, which can achieve the provider quickly. The second property is node similarity; it determines the similarity between request requirements and nodes using distance similarity. The intermediate node that has the higher probability is chosen to receive the request.
A service discovery and selection model [
30] is proposed based on artificial potential fields (APFs) which is initially introduced by [
31] to resolve the reboot navigation problems in dynamic environments. In this model, for each node a service agent is responsible for the provision of a service and the requester agent is responsible for the management of the incoming requests. When a node receives a request, the service agent gets the requested service and verifies if it can be executed by this node, elsewhere the requested service is sent to the most promising node by the requester agent using the resultant force of APFs. The resultant force is a combination of service satisfaction and availability; it can be either attractive or repulsive toward the neighboring nodes. The service satisfaction assures that the next node can execute the desired service for a request, and the service availability assures that the time of waiting for the desired service is fewer for the next node. The service availability makes nodes to choose different intermediate nodes for each request. The number of hops required is reduced and the queue length (the number of services waiting to execute) among nodes is balanced in comparison with the flooding-based approach [
32].
Authors in [
33] proposed an approach to discover and search for a specific service in SIoT among communities, where a community is defined as a cohesive group of nodes that are densely connected to each other and sparsely connected to the other nodes in a SIoT. The communities are constructed based on preference and social similarities, and subcommunity within a community is constructed based on services similarity. The coordinator node (considered as the master node of a community) is responsible for holding the services of the community. When a node receives a request for a service that is not within the subcommunity of the node, it forwards it to the coordinator node of a neighboring community until the provider node is found. The experimental results show that the proposed approach has a promise results in terms success rate, average delay, and modularity.
As the search for a specific service in SIoT is performed in a distributed manner with only local information, it is important to apply a method that makes the task efficient, subject to the energy consumption of nodes. As illustrated in
Table 1, there are studies focused on the enhancement of the network navigability (giant component, average path length, average degree, local clustering coefficient, diameter) during the friendship selection to obtain an efficient search task, but this strategy is not enough to speed up the search for a desired service. While the other ones focus on service search itself in which the friendship selection has been assumed already performed by nodes (assuming that the social network has already been created). However, in both cases the energy consumption of nodes and the network lifetime are not considered. Our approach deals with the problem of service search in SIoT considering network navigability, service discovery/search itself, energy consumption of nodes, and network lifetime.
3. Preliminaries
This section presents the necessary background for understanding the remainder of this paper, including the problem definition and the parameters of a network.
3.1. Problem Definition
In a constraint network, each node has a set of neighbors, where the communication is one hop (from a node to another), in both directions (undirected network), and is unicast (a request is sent to just one node).
In a social network, each node has a set of friends which are considered useful neighbors to reach the requested services. So, the problem consists of how to select these friends in a way that can improve network navigability. Furthermore, the search process must be rapid with an increased network lifetime.
In more details, when any network does not achieve the total giant component (100%), the possibility to respond to the users’ or nodes’ requirements will be decreased. The average degree should be minimized considering that the total giant component should be maximized, where a high number of friends affect the nodes’ capabilities such as power energy and memory capacity. Moreover, the minimization of average path length and diameter, and the maximization of the average local coefficient boost the service search to find a short path from a requestor to a provider. Besides, until the provider node is not achieved, the request/queries should move through the nodes that have high capabilities, especially the ones with sufficient energy. This is because intermediate nodes with insufficient resources could break down after several tasks.
Figure 2 shows a simple example of a social network (it is considered as a mesh-like network), where links represent friendships’ connection ties, while the dashed lines are the path followed by node S to reach the provider node D. When a node S receives a request, it can retransmit or execute it; in case of retransmission, the node S can choose the friend A, and by the same manner, the request will reach to the provider (executor) node D. The path achieved by the request in this example is the shortest path length; it makes the service search rapid, but that does not mean that it is the best path. Node A can transmit the requests more frequently than others; therefore, it will consume more energy. For this, during the search phase, the best path to achieve a provider is a short path (for the rapid search phase), where the associated/constructed nodes have sufficient energies (to extend the network lifetime [
34]).
Table 2 summarizes the main notations used in the rest of this paper.
3.2. Parameters of a Network
There are a set of parameters that are computed to measure the efficiency of a network. In the following, we explain the most important parameters for the undirected network as discussed below.
The giant component: it is a connected component of a network that contains a significant proportion of the entire nodes in the network.
The average path length: it measures the efficiency of information or mass transport on a network and it is calculated as follows:
where N is the number of nodes and
is the shortest path length between two nodes i and j. The shortest average path length boosts the rapid transmission of data and reduces costs.
The average degree: The degree
of the node i is the number of its neighbors/connections. The average degree of a network is calculated as follows:
The average degree increases with the increase of the number of connections among nodes.
The local clustering coefficient: It measures how close the neighbors of a node are to make a complete graph, and it is calculated as follows:
where
is the number of edges among the neighbors of the node i, and
is the number of neighbors of the node i. The average local clustering coefficient of a network is computed as follows:
Diameter of a network: It is the shortest path length between the two most distant nodes in a network.
The giant component, the average degree, and the local clustering coefficient values of a social network are always fewer than or equal to those of its initial network. Whereas, average path length and diameter values in social network are always greater than or equal to those of its initial network.
4. Our Proposal
In this section, we present a new approach to create a social network and manage the service search by taking into account the nodes’ capabilities. As stated above, several factors may impact these tasks, such as network navigability, the number of hops to achieve the providers, and the network lifetime. The main novelty of our contribution is to address all these criteria at once, and it is designed to maintain the 5th generation wireless technology.
4.1. Main Steps
The objective of this contribution is to create a social network that can improve network navigability, boost rapid service discovery, and prolong the network lifetime, knowing that the enhancement of network navigability alone is not sufficient to quickly search for a service.
Algorithm 1 shows the main steps to achieve our objective. At first, the nodes create groups dynamically, where each group possesses only one master. Then, the master groups agree on a specific value using a consensus algorithm. After that, the friendship selection begins using the agreed value and other properties. The three steps above are applied once.
Algorithm 1: The general steps of our contribution |
1. /* Initial phase */ |
2. Creation of groups |
3. A consensus algorithm on a common value |
4. Friendship selection |
5. /* Second phase*/ |
6. Sorting the friends |
7. For each request |
8. Service search process |
9. / / Resorting the friends if needed |
10. End |
The scenario of the proposed algorithm can be given in case of a smart city where a large number of devices are connected peer-to-peer and each device is surrounded by connected devices, such as, monitoring of temperature, monitoring of temperature, control electricity consumption, human detection movement, human detection, human identification, etc. The devices can request each other (one-hop communication) for a given service until the target device is found. The devices that exist in the same communication range could create a group dynamically according to some criteria (
Section 4.2). Then the devices will create a social network by selecting a set of devices as friends (
Section 4.5) that will be capable to achieve efficiency at the destinations of a device, for example, a detection movement device can use monitoring of temperature and monitoring of temperature devices as friends. For efficient service search, the devices sort their friends periodically (
Section 4.6) considering the capability to process the incoming requests and rapid search process (
Section 4.3).
The social network is created to improve network navigability, to be a suitable network that can be used to prolong the network lifetime, and to support the optimal paths during the service search task. The service search can be launched after the creation of the social network. Each node sorts its friends in a decreasing manner in order to balance between the rapid search and the available resources. When a node does not find any friend that can provide or execute a given service, it chooses the friend on the top of the list to receive this request.
4.2. Construction of Node Groups
The construction of groups is used principally to support a social network that improves the network navigability and initialize the balanced resources between friends. However, its role is secondary during the search phase.
In IoT networks, there are nodes with a low number of connections and others with a high number of connections, and with different capabilities. Therefore, a semi-uniform distribution of density and resources is needed. Furthermore, the search process in lossy networks is often not exploited due to several reasons, such as the longest path length from the requestor to the provider, a high number of services, limited capabilities of the nodes, etc. To deal with these issues, the mechanism of groups is adopted as a key concept to achieve the given goals.
A mechanism for automatic and self-organizing groups has been proposed, the groups are created according to two rules as stated below:
Rule (1): In an area with N neighbors, the node with a high number of connections has a priority to be the master group.
Rule (2): The group with a low number of members has a priority to add a new node.
Each node has information about its neighbor nodes (nodes that are in communication range) such as the number of connections, information groups (if they were constructed), etc. A node i sends a request to join as a member node to the node j (candidate master group) that has a high number of connections, if the node j has a high number of connections for all neighboring nodes such that it possesses a high capacity (for example residual energy is more than 50%), in this case, the node j responses positively for the node i. In the second scenario, when a node j sends a request to join as a member node and receives a request to be considered as the master node, node j will choose to be as member node and respond negatively to the request (Rule 1). In the third scenario, when a new node has been deployed in an area, firstly, it gathers information from its neighbors, secondly, it sends a request to join the group that has a low number of members (Rule 2).
Rule (1) makes the network assemble a set of nodes that have low degrees within the node that has a high degree; its goal is to expand the proportion of connections when the social network is created. The objective of Rule (2) is to decrease the difference that exists between groups in terms of cardinality.
During the discovery/search phase, the importance of groups is decreased, where each node has its own capability to realize tasks independently from its master group. The nature of groups is flexible in order to avoid some problems related to the creation of groups, such as nodes’ mobility.
Figure 3 provides an example of the groups’ creation in a simple lossy network; there are four groups G1, G2, G3, and G4 with 9, 8, 7, and 8 nodes, respectively. The number of nodes in the groups does not exceed 9 (Gmax = 9).
4.3. Available Resources and Search Factors
To determine the nature of the available resources of a network, node and group capabilities are proposed. Furthermore, the group centrality and popularity predict the search path of a request to achieve the provider rapidly.
Node capability:
Node capability is a set of properties of a node such as quality of service, capacity of storage, power energy, etc. It combines all these properties and takes into account the weight of each property. We categorize the properties into two types:
Maximized Property: when we want to select the best node, we search for a high value of certain properties such as power energy, memory capacity, etc.
Minimized Property: when we want to select the best node, we search for a low value of certain properties such as execution time, etc.
We normalize the property
of node i by calculating the value of property
which is given below:
where
and
The Equation (5) allows to limit the values of properties in range 0 and 1, and to determine their influence for each node.
After that we define the node capability
as follows:
where
is the weight of property
,
,
is the number of properties, and
.
Equation (6) combines all properties of a node with the weight of each property to determine the capability of the node using the normalized values obtained from Equation (5). The node with a high value of capability denotes a high efficiency. The most capable nodes are preferred to be master nodes or intermediate nodes.
Group capability:
We define another factor related to the capability of a group, which is the capability of all nodes in the group (master node and member nodes). Group capability
of the group k is defined as follows:
where
, and
is the cardinal of group k.
Equation (7) combines all capabilities of nodes in a group to determine the group capability using the capabilities values obtained from Equation (6). The group with a high value of capability denotes a high efficiency. The most capable groups are preferred to be intermediate groups for requests.
Group centrality:
In a social network, we define the centrality of group
, which depends on the number of nodes
and the sum of friends of each member h in the group k as given below:
where
is the number of friends of the node h. The highest value of the group centrality refers to the high values of
and
, and indicates the probability to find rapidly a provider through this group. Equation (8) uses the cardinal of the group and the number of friends of friends in this group, where the group with a high number of nodes that have a high number of friends is preferred. For that, the group that has a centrality degree is preferred to find quickly the provider nodes.
Group popularity:
In a social network, when a node does not find a friend that can provide/execute the requested service, it chooses the receiver of the request using the group popularity. More precisely, the node knows the neighbor group that is declared in such path execution or path discovery, when this group is declared multiple times; that means it has a high probability to be selected to transmit the given request to the provider. For that, we define the group popularity
of the node i as below:
where
(resp.
) is the number of times that the group k (resp. z) is declared in the path discoveries or executions,
is the groups of friends of the node i, and
is the cardinality of
.
The high value of group popularity of a node denotes that the group is more used for the requested services.
Equation (9) is used to calculate the degree of popularity of a group based on the previous paths found by friends for the executed requests. The group with a high popularity value indicates that there is a high probability to find provider nodes via this group.
4.4. Agreement on the Common Group Capability Using a Consensus Algorithm
The master groups agree on a common capability value, which is named AC, and they calculate it based on the capabilities of all groups using a consensus algorithm. We cannot initialize AC because it must be between the minimum and maximum capabilities of the groups, and these capabilities are determined by the nodes themselves.
Algorithm 2 is used to find AC, and was proposed to agree on the same clock for synchronizing a wireless sensor using local information [
35], with a decentralized manner. It is a simple and lightweight algorithm.
Algorithm 2: An agreement on common value AC |
1. : Capability group value |
2. : Deviation factor |
3. : The neighbor masters of the master node j |
4. Main Loop |
5. t = 1 |
6. While (non-converge) |
7. Each master j sends to |
8. For each master i from |
9. |
10. End |
11. End |
At first, each master group j sends its group capability
to its surrounding master groups i. Thus, each master i adjusts its value of
, using the following formula:
where
, t is the iteration number (it is also considered as an instant), and
is the deviation factor
.
In each iteration master node i calculates the sequence , if for k iterations, the Algorithm 2 will be converged for node i, where is a threshold value, and k is the number of surrounding master nodes.
The value of is initialized by the capability of a group, in this case AC value is always between the minimum and the maximum capability of groups as declared in the next proposition.
Proposition. Letbe a positive integer, anda set of sequences such thatif,,andfor all i
in , with m and M two real numbers. Then: Proof. We proceed by induction on t. For t = 0, we have so, the proposition is true at t = 0 for all i in . □
Let , assume that , we will prove that for all i in .
So, we have
that means
by the same method, we find:
The addition of two inequalities (*) and (**) will be:
So, the proposition is true for t + 2, in the finally the proposition is true for t + 1.
4.5. Social Network Creation
The objective of the proposed social network is to improve the network navigability, support the rapid service search, and initialize a semi-balance of the available resources. The friendship selection strategy uses the obtained groups, AC value, and other criteria to create a social network that can achieve the goals stated above.
Firstly, each node selects its neighbors that belong to its group as friends. Then, while the maximum number of allowed friends does not exceed Fmax (the maximal number of allowed friends), the process of friendship selection is performed using Algorithm 3.
Algorithm 3: Friendship selection |
1. Notations |
2. : The master group of the node i |
3. : The capability of node x |
4. : The list of the friends of the node x |
5. : The list of neighbors of the node i |
6. : The list of groups of the friends of node i |
7. : The sum of capabilities of nodes in |
8. : The correspondent criteria are verified by j |
9. Output: Social network |
10. For each node i |
11. Send , , , , and to |
12. End |
13. For each node j from do |
14. If == true |
15. Send confirmation to the node j |
16. |
17. |
18. |
19. |
20. Else |
21. Decline the friend request |
22. End |
Secondly, each node i sends friend requests to its neighbors that are accompanied by the group id, the capability, the list of friends, the sum of friends’ capabilities, and the list of groups in which its friends belong to. Thus, when a node j receives a friend request, it checks the corresponding criteria with node i, they are verified if each criterion below is true:
Criterion 1: Nodes i and j belong to different groups.
Criterion 2: Non-common friends between groups of i and j.
Criterion 3: The friends’ sum of capabilities of i and j should be less or equal to the AC value, respectively.
Criterion 4: The number of friends of i and j must not exceed Fmax.
The following set of criteria is taken into consideration when creating a social network:
The nodes will have the same role, no master node is needed.
The diversification of friendships in an area, where each node has friends that belong to different groups.
The enhancement of network navigability.
The initialization of a balanced resource between groups (same group capability AC).
The support of the rapid service search mechanism.
The degree of friends will be in the shortest range.
4.6. Friends Sorting for Service Search
To reach the providers rapidly and balance the available resources during the service search process in a social network, the ordering and reordering of friends is performed by the nodes.
To choose the efficient friends, we calculate the sorting factor based on four factors which are: capability of node c, capability of group , centrality of group , and popularity of group .
is the factor value of node j at node i, and it is given by:
where
,
,
and
are the weights of
,
,
and
, respectively,
,
, and j belongs to group k.
Using the sorting factor, the nodes list their friends; the node with the highest value of will receive the future request. Furthermore, the sorting factor is recalculated after a period of time.
Below some explanations and limitations of the proposed solution.
Our proposed approach considers several issues that can happen during the communication among nodes in SIoT by supporting self-organization and self-healing. Each node has different friends and the communication is decentralized using local information. For that, the failure that can happen at the level of a node is local. Thus, the failed nodes are avoided in the incoming requests according to the sorting factor proposed in subsection.
The friendship selection in our proposed work is based on four factors: node capability, group capability, popularity, and centrality. Each node has different friends that are sorted periodically based on their capabilities (
Section 4.6), such that the most capable nodes will receive the incoming request, they have higher residual energy than other nodes in a community. Using the proposed mechanism, the residual energies of all nodes will be semi-balanced, which increases the lifespan of nodes. In our work, we try to increase the lifespan of nodes to avoid their failure. In the case of the failure of the non-master node, it will be removed from the friends’ list of all nodes.
The master node is the most competent node in a group, which is selected based on its capability, it has more energy than others in the group. Moreover, the role of the master node is flexible, its importance is to make an agreement on a group capability between surrounding master nodes, where this task is realized once. After that, it is considered as a normal friend. Then, if the master node fails, it will be removed from the list of friends without affecting the communication in the group.