Next Article in Journal
A Conceptual Architecture in Decentralizing Computing, Storage, and Networking Aspect of IoT Infrastructure
Previous Article in Journal
Cyber Threats to Industrial IoT: A Survey on Attacks and Countermeasures
Previous Article in Special Issue
Process Automation in an IoT–Fog–Cloud Ecosystem: A Survey and Taxonomy
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:

An Agent-Based Model of Task-Allocation and Resource-Sharing for Social Internet of Things

Faculty of Computing and Information Technology, Sohar University, Sohar 311, Oman
Department of CS, University of Science and Technology Bannu, Bannu 28100, Pakistan
Computer Science Department, City University of Science and Information Technology Peshawar, Peshawar 25000, Pakistan
Author to whom correspondence should be addressed.
IoT 2021, 2(1), 187-204;
Submission received: 20 February 2021 / Revised: 21 March 2021 / Accepted: 22 March 2021 / Published: 23 March 2021
(This article belongs to the Special Issue The Leverage of Social Media and IoT)


The things in the Internet of Things are becoming more and more socially aware. What social means for these things (more often termed as “social objects”) is predominately determined by how and when objects interact with each other. In this paper, an agent-based model for Social Internet of Things is proposed, which features the realization of various interaction modalities, along with possible network structures and mobility modes, thus providing a novel model to ask interesting “what-if” questions. The scenario used, which is the acquisition of shared resources in a common spatial and temporal world, demands agents to have ad-hoc communication and a willingness to cooperate with others. The model was simulated for all possible combinations of input parameters to study the implications of competitive vs. cooperative social behavior while agents try to acquire shared resources/services in a peer-to-peer fashion. However, the main focus of the paper was to analyze the impact of profile-based mobility, which has an underpinning on parameters of extent and scale of a mobility profile. The simulation results, in addition to others, reveal that there are substantial and systematic differences among different combinations of values for extent and scale.

1. Introduction

Internet of Things (IoT) [1] is claimed to be the most advanced and sophisticated futuristic technology by many people [2] and is more ubiquitous and social compared to more recent technologies. Social Internet of Things (SIoT) [3] is an emerging area in research, in which IoT is augmented with social capabilities. The characteristics of the social aspects of objects of SIoT has been evolving with time [4]. The discussion on things of SIoT, which started in terms of smart objects, is now shifted towards acting objects. The smart objects have the capability to communicate with social networks of humans while the acting objects are the virtual objects representing humans on their behalf. Researchers have developed many applications for these domains, however, the actual challenge is about modeling the social objects, which are capable of creating and managing their own social networks [5,6].
Seemingly, SIoT (comprising social objects) is the next big thing. However, there is a potential danger of enthusiastically adopting a technology without considering its disadvantages. Looking at the recent past, it cannot be denied that our society has experienced adverse consequences of having a careless attitude towards adopting Internet-based technologies for social networking and mobile computing [7]. Since there are no limits on the scale and inclusion of objects in the IoT domain, it is very important to foresee the outfalls of it. In summary, the social objects must be carefully modeled, otherwise, the interactions, actions, and influence of social objects due to their self-maintained social networks may turn them to be biased, disadvantageous, or sometimes even destructive for society [4,5].
The unprecedented growth and popularity of social networks have a significant influence on researchers of various domains, including SIoT research [5,8]. We believe that thinking beyond social networking is needed for more meaningful arguments about SIoT. Social objects of SIoT must be assumed to have a decentralized, ad-hoc, limited, and localized structure. These features provide a perspective that is not always applicable to social networking. Towards this, in our previous work [6,8], we developed a framework suggesting that the social objects:
  • should be decentralized in nature.
  • should be capable of taking autonomous decisions.
  • should be interacting with other objects within their zones of influence, described by network configurations.
  • could optionally be mobile, which result-in ad-hoc connectivity and, thus, the interaction among objects.
Therefore, the framework used in this paper is of a combinatorial nature, combining societal aspects and features of distributed computing paradigm. That is, the social objects must have a self-organizing and autonomous nature. Based on the idea of agency [9], these objects should have a self-organized collective behavior, which is based on their own interactions with other objects instead of coming from a centralized controller [10]. Since interactions among the objects need connectivity, there is a risk of being disconnected due to mobility and, thus, it must be dynamically restored. This work uses the Peer-to-Peer (P2P) paradigm [11] as a classical application of ad-hoc connectivity and assumes absolute trust among the interacting peers, as suggested by Atzori et al. in [5].
In this paper, we proposed an agent-based simulation framework to explore important what-if questions regarding the potential impact of social capabilities acquired by the social objects in a P2P setting to be tailored for sharing common resources. The model is enriched with competitive and cooperative behaviors as two overlying principles for sharing common resources. The objects take distributed decisions and have zero assistance from any centralized body. The agents are therefore autonomous and they make their own decisions based on the local knowledge acquired from the network they have formed. This work considers different types of social networks based on their initial configurations and dynamics. Agents are allowed to move using one of the three mobility models. We assume that all the agents are available and are visible to each other. For simplicity, we consider that all agents are equally accessible in their neighborhood and they have unconditional trust for each other.
To address challenges such as high latency, low capacity, and network failure, current IoT applications are shifting from the centralized cloud computing paradigm to the decentralized fog computing paradigm [12]. The fog provides services that are tailored for faster response and greater quality, based on the principles of distributed computing. Still, this new technology is not really geared up for adaptation and self-organization. The generalized agent-based resources provisioning framework proposed in this paper will help draw the guiding principles for a self-organized fog technology, particularly for futuristic social objects. According to [13], the two main challenges of fog computing are resource allocation and task scheduling. The prime focus of the presented framework is resource allocation and task scheduling, although the agents used are IoT devices and not fog servers. However, the lessons learned can be replicated for fog servers as the underlying communication paradigm (i.e., P2P computing) is the same. In addition to that, the social dimension incorporated can result in a mechanism to resolve conflicts among the fog servers; this aspect has not been a focus in fog computing until now.
The rest of the paper is organized as follows. Section 2 presents the background and motivation for this work. Section 3 provides the proposed model, which is followed by simulation and results in Section 4. This paper ends with the conclusion presented in Section 5.

2. Background and Motivation

2.1. Internet of Things

In the past decade, the Internet of Things (IoT) has gained remarkable attention from both researchers and industry. According to CISCO analysis [14], by 2023, IoT will account for 50% i.e., 14.7 billion global networked devices, which indicates a huge market [15]. A number of interest groups have been working to define standards and frameworks for the IoT. Leading IT companies have invested a considerable amount of money to introduce a number of IoT based products and services such as Nest by Google (, accessed on 20 January 2021) and SmartThings by Samsung (, accessed on 20 January 2021). Prominent ICT organizations such as Ericsson, Amazon, Huawei, and IBM have introduced IoT based solutions for different problems. Recently, Huawei’s Ocean Connect [16] has presented a sophisticated IoT platform.

2.2. Social Capabilities of Things in SIoT

SIoT is an emerging area in research, in which IoT is augmented with social capabilities. The more common trend is to take SIoT as an extended social network of the people, where the things belonging to a person or a shared environment appear as augmentation of the prevailing social network. Whereas, the less common trend is to consider things in SIoT creating and maintaining their own social network. Although things can have belonging/ownership relationships with people, it is not mandatory. This paper is related to the latter trend.
Specifically, in a fog computing environment, a framework to overlay social and fog links is proposed in a recent paper [17]. We propose a model that only focuses on social objects and their potential ability to act in collaboration. Obviously, objects managing their own social network must provide collaboration-based solutions to the problems such as shared utilization of resources, distributed decision-making, and cooperative workflows. One of these problems, i.e., the utilization (through scheduling and allocation) of shared resources, is taken up as a scenario in this paper.

2.3. From Centralized to Distributed Communication

Computer networks allow computers/devices to exchange data [18]. In the past, resources would be placed on a centrally-managed server, accessible by the client machines, whereas, P2P architecture allows machines to share their own resources in the network such as file storage, processing power, and peripherals with another machine connected to the same network with or without any dedicated server [19,20]. Thus, a machine works both as a server as well as a client in P2P networks. P2P technology allows the distribution of contents without any central facility of large resources in terms of storage, computation power, or network bandwidth [20,21].
P2P technology empowered an uprising in Machine-to-Machine (M2M) communication. With an exponential increase in the number of machines, the need has arisen to decrease their cost for allowing communication among even very trivial and small objects around us. This endeavor has resulted in some modern systems and technologies such as Cyber–Physical Systems, Wireless Sensor Networks, Human–Agent Collectives (socio-technical systems), and IoT [22].

2.4. SIoT Applications

These technologies have resulted in the Industry 4.0 revolution. Industry 4.0 [23,24] is a European initiative for ensuring efficiency, sustainability, and safety of future industrial systems by integrating them with new technologies. According to [25], collaboration is a key challenge for the Industry 4.0 initiative. Several social aspects, such as evolving network dynamics, behavioral and trust modeling, strategic decision-making, and collaborated group achievement and optimization, have been identified. To cope with these challenges, the underlying network for the Industry 4.0 needs to be at least socially-aware.
Another application area of IoT is smart cities. Smart cities have similar characteristics as that of Industry 4.0. Definitely, it is more important that the IoT objects in a smart city have social capabilities, e.g., smart vehicles. Similar to SIoT, the concept of Social Internet of Vehicles (SIoV) is also gaining popularity, where vehicles use the Internet to socialize with other components of the transportation system including other vehicles, drivers, passengers, and infrastructure [26]. Also, models and applications of smart vehicles forming and maintaining their own social network have started to emerge. For example, in [27], the authors proposed a model, in which the vehicles not only acquire recommendations from the social network of their owners, but also from a social network among themselves, oriented towards a more precise and context-based recommendation.
Nevertheless, even the most recently published work on SIoT applications for smart cities (and Industry 4.0) exploits user data (and social networks of the people owning IoT objects) to provide contextualized IoT services [28]. Our research focuses on social networking among the objects of IoT, which has the potential to have a huge impact on how we think about SIoT these days. Towards this, we have proposed a generic agent-based model based on desired characteristics (as stated in Section 1). However, the model can be applied to any SIoT application. We applied our model to the most common and important application of such environments, i.e., fair and robust resource-sharing in a P2P infrastructure.

2.5. Related Work in Modeling SIoT

The authors of [29,30] explored the effect of IoT technology and its applications on human values, particularly highlighting the significance of trust in improving person-to-person communication by means of IoT technology. A model for evaluating honesty is presented in [31]. In [32], the authors conducted an IoT-based experiment to validate people based on the pattern of their activities, demonstrating the importance and relevance of social aspects. Probably, the first reference about can be traced back to Atzori et al.’s paper [33], where they emphasize on “social network of intelligent objects”. This paper certainly introduced the concept of objects (of IoT) forming and maintaining their own social network.
A recent survey paper addresses agent-based models of IoT [34]. Typical to SIoT, an overwhelming majority focus on networking [35], systems [36], and social networking aspects of the people [3,37]. Literature on things maintaining a network of their own is quite limited. The closest we get is the concept of speaking objects [38], which actually focuses on augmenting social objects with humans’ speaking attributes. Specific to modalities of IoT services, an opportunistic services modeling configuration framework is proposed by Fortino et al. [39,40], and via aggregate computing, this model was used for crowd detection and steering [41]; however, aggregation and opportunism was implemented via a system’s viewpoint. For a truly social system, the collective (coordination) should also be based on social dimensions.
Hauert studied the detailed functionality of social systems based on competition and cooperation, which are usually classified as competitive, cooperative, and those both cooperative and competitive in nature [42]. Cooperation within peers has been found among several natural systems [43]. Competitively trained human societies [44] have started to evolve as cooperative societies [45]. Therefore, the impact of this transformation (from competitive to cooperative mode) is analyzed in several studies. For instance, the authors in [46] explored the impact of migration for the outbreak of cooperation, with the help of a simple interactive scenario based on iterated Prisoner’s dilemma. However, it is a population-based model and does not place emphasis on the specific characteristics of the interacting entities that are essential to inspect the emergence of cooperation. Koponen and Nousiainen developed an agent based model to study the evolution of mutual recognition within small groups [47]. Despite the fact that the intuition of the model is based on social interaction, it is unable to produce the functional requirements of the activities accomplished using interactive agents.
Caram et al. developed an agent-based interaction model, P2P in nature, to explore the efficiency of interaction patterns [10]. They compared the efficiency of interaction in an environment where the model was influenced by communal aspects of competition against cooperation. According to their proposed model, when common resources are shared, the possibility of communication among the agents increases as the difference between agents’ sizes increases. An agent gets a portion of the commonly shared resource, which is directly proportional to its size. The peers cooperate with each other, if any only if, one agent offers while the other receives the service. The proposed model is for use in symmetrical environments, which are described in terms of the functionality, services, and network patterns of agents. This work is inspired by the model described above and suggests an agent-based model, which is influenced by the rules of social interaction in an asymmetric setup, particularly tailored to SIoT.

2.6. Outline of the Proposed Model

In our previous work [6,8], we provided evidence of the usefulness of things maintaining their own social networks, in the case of a fair utilization of shared resources. The results show that an overall cooperation among the agents’ outperforms competition. It also observed that the network structure is important for meaningful cooperation. The mobility of the objects was another dimension that was considered [48]. Three mobility modes, stationary, random walk, and profile-based mobility, were considered during the evaluation. In this paper, we provide a deeper understanding of the impact of profile-based mobility on the efficiency of sharing common resources among the things of SIoT. In this connection, we have introduced two behaviors/variables, i.e., extent and scale, which are used during the profiling stage. The extent means that how many possible destinations a thing may have while creating a mobility profile. For example: if it is x, it means that the thing can have a maximum of x destinations. If that thing is a key-chain and the person carrying it is quite mobile, the value of x would be higher as compared to a person who is not that mobile. The scale represents how far away (on average) one destination is from another one. This factor is, thus, helping in differentiating a larger city/environment from a smaller city/environment. A comparative analysis of the extent and scale of profile-based mobility will definitely enlighten and enhance our understanding of the potential and limitations of SIoT.

3. Model

This section is devoted to the model description. The model is documented using the Overview, Design concepts and Details (ODD) scientific protocol [49,50], typically used for agent-based models and simulation.

3.1. Overview

The model overview focuses on purpose of the model, state variables and scales used, and an overview of the simulation process and scheduling.
Purpose: The purpose of the proposed model is to study the impact of social capabilities of agents (things in the context of IoT), where the P2P sharing of common resources is taken up as a scenario. It studies the implications of competitive vs. cooperative social paradigm in an environment where the peers try to acquire shared resources/services. The model adheres to the notion of “social objects” presented in [5]. In addition, the model supports asymmetric peers in terms of their capabilities and configurations of services. It also adopts different characteristics of objects’ regarding networking and mobility. In particular, the focus of the model is to have a comparative analysis of the extent and scale of profile-based mobility.
State variables and scales: The simulation world used in this work is a space that comprises cells in a form of 2D grid. These cells are called patches in NetLogo [51]. Agents (IoT objects) reside on top of these patches and exchange information with their neighborhood (can be proximity as well as distant) and may acquire a strategy to change their positions. In addition to these discrete spatial features, the model also uses discrete time, that is, the simulation of the model progresses in iterations.
The agents are assigned one of the two possible roles. An agent could be either a service consumer (a normal agent) or a service provider (a peer). The model offers four services, which require different times in terms of iterations, to complete. The variable duration_in_current_status (DICS) is used to track the time of an agent in a specified state. It helps the agent in the transition from one state to another when certain conditions are met. The proposed model uses a number of other variables for defining an agent’s activities, timings, and availability, whose detailed descriptions are given in [6]. The table current_services_completed (CSC) contains the list of all services recently acquired by an agent. Hence, these can be offered to other agents subject to availability and selection. A peer during the provision and an agent during the consumption of a service are not available to others.
Process overview and scheduling: Each agent executes a six-state resource-sharing process at each iteration, followed by the process of interaction (to update its network) and a possible move to a new position. The process of acquiring a service is based on six states, namely: OFF, IDLE, ASSIGN, SEARCH, PROCEED, and SERVE. The social behavior of competition and cooperation is embedded into these states. Each iteration in the simulation is modeled to execute one minute, so a day equals 1440 iterations. We ran the simulation for 10 days, which equals 14,400 iterations. Initially, the services were scheduled for a day and the same was repeated for the rest of the days. This gives us sufficient time to look at long-term behavior and, thus, ignore possible out-of-pattern outcomes of the first day.

3.2. Design Concepts

Basic Principles: The proposed model addresses the basic principle of using discrete time and space simulation to evaluate the social capabilities of SIoT. Different models of agents’ cooperation, networking, and mobility were tested to perform a comparative analysis of various social aspects in terms of common shared resources.
Emergence: We expect that a population of things having cooperative behavior would emerge as being more successful than the one having competitive behavior. We also expect that after an initial random behavior on day 1, the population in all cases would settle down to a regular behavior for the rest of the days.
Adaptation: The adaptation of behavior is a central part of the model. The agents adapt on the basis of the neighborhood that they get with mobility. The stationary agents also adapt on the basis of the availability of both local and distant neighbors.
Objectives: The basic objective behind the adaptive behavior of agents is to enable them to have a fair share of common resources.
Sensing: Sensing plays a vital role in decision making. Agents need to sense the current state of neighbors and the services that they can provide.
Interaction: Different types of interactions between the agents enable various activities. The interactions take place between the neighbors, both within the proximity and at distance maintained using links.
Observations: Simulation results were evaluated based on the following quantitative measures:
  • Service units denied: represents the total number of service units in terms of iterations (time) that are denied (peer requested with no response) by the system at a given time.
  • Service units completed: maintains the total number of service units in terms of iterations (time) that are completed by the system at a given time.

3.3. Details

This section provides details about the sub-models used in this work. The models are closely entangled with the specification of services and basic interaction capabilities of agents. The agent-based models of competition and cooperation are presented in Section 3.3.1 and Section 3.3.2 in order. A model of friendship with increasing repetitive interactions is provided in Section 3.3.3. The mobility and networking models are given in Section 3.3.4 and Section 3.3.5 respectively.

3.3.1. Model of Resource Sharing in Competitive Mode

Figure 1 represents the resource sharing model for peers in competitive mode. Basically, the state transitions happen based on the services required and served by a peer. An appropriate peer (which can provide the service) from CSC is searched and chosen. The request-response cycle is then initiated. The peer either starts serving the requesting agent or denies the request. A peer denies a service when it is busy or it has inconsistency in terms of connectivity. In case of denial, the agent would keep searching for another peer. This behavior is typically interpreted as both agent and its peer being in a competitive mode.

3.3.2. Model of Resource Sharing in Cooperative Mode

Figure 2 shows the resource-sharing model of peers in cooperative mode. Cooperation is expected to improve the resource sharing efficiency of the system. The actual cooperation happens when two or more agents search for each other. In this case, a cooperation between the competing agents would occur based on the value of DICS. When the DICS value of the requester is greater than the DICS value of the respondent, the potential respondent would quit in favor of the requester. An entirely opposite does happen when the DICS condition is false.

3.3.3. Model of Friendship (Restricted Cooperation)

The friendship model enables restricted cooperation among friends only, when it is possible, instead of unconditional cooperation offered by the model presented in Section 3.3.2. Repeated encounters turn a neighboring agent into a credible contact, which infuses credibility into the resulting interactions [52]. Similarly, repeated encounters turn a credible contact into a legitimate friend, which introduces legitimacy in the resulting interactions [52]. In this mode of cooperation, a legitimate interaction has priority over a credible interaction, and a credible interaction has priority over unconditional interaction. This mode of cooperation is termed restricted due to the above-mentioned reason.

3.3.4. Mobility Modes

The proposed mechanism operates under the following three mobility modes:
  • Mobility 1: No mobility, in which all agents are stationary.
  • Mobility 2: Random walk, in which the agents choose a direction to move randomly at each iteration.
  • Mobility 3: Profile-based walk, in which the agents select some random locations to move to, and they move from one location to another.
Stationary and random-walk mobility modes are obvious. In profile-based mobility, agents decide some random location in their surroundings to move to and, then, regularly move from one location to another. This mobility mode is governed by two variables called: extent and scale. The extent represents the number of destinations an agent might have while creating a mobility profile. The scale shows the average distance between the destinations.

3.3.5. Networking

The network is dynamically configured at each iteration. A mesh network as a base case represents the possibility of an agent to access any other agent in the environment. A regular network enables an agent to interact with its local neighbors. A small-world network [53] augments a regular network with a few long-distance connections.

4. Simulation and Results

4.1. Simulation Setup

NetLogo, an open-source simulator, based on agent-based modeling, was used to simulate the proposed model in this work [54]. A series of parametric settings are possible for simulation purposes based on the strategies of cooperation, network configurations, and mobility modes. This work uses the following three strategies of cooperation:
  • resource sharing when all agents are in competitive mode (see Section 3.3.1).
  • resource sharing when all agents are in cooperative mode (see Section 3.3.2).
  • resource sharing when all agents are in restricted cooperative mode (see Section 3.3.3).
The agents in each strategy adopted the above maintain one of the three dynamically changing networks called: mesh, regular, and small world (see Section 3.3.5). The agents in each selected network acquire one of the three mobility modes: stationary, random walk, and profile-based (see Section 3.3.4). Density, interaction radius of agents, and beta value of small work network are other important parameters. The density shows the number of agents with reference to the available space while the beta value provides the fraction of long-distance connections of the small-world network.

4.2. Simulation Results

In our earlier publications [8,55,56], we used a number of combinations based on the above-mentioned parameters, and reported the following results:
  • In [55], it is reported that “cooperative strategy is comparable with competitive strategy, particularly, when the population is large. It is expected that cooperation would always outperform competition above a density threshold”.
  • In [56], we learnt that “the nature of the underlying structure of network connectivity has a profound impact. In general, peers communicating in a mesh network achieve the best results. However, in some settings, a small-world network competes with a mesh network. Further, with an increase in the density of objects, the beta value of small-world may be reduced without degrading the standard of service provisioning.”
  • The results in [8] suggested that “As a whole, cooperation between peers improves the system. In particular, cooperation in a restricted network is never counterproductive; in-fact, it is evident to be marginally better than open-ended cooperation.”
The above-mentioned results are also reaffirmed by the fresh simulation performed for this paper. Figure 3a presents the units denied in case of competitive strategy. The comparative analysis of different mobility models suggests that units denied are more likely to be stationary agents than the cases where the agents are mobile; marginally more in random walk than profile-based mobility. When competitive strategy is compared with cooperative strategies—cooperative (Figure 3b) and restricted cooperative (Figure 3c)—the difference is huge, less than a magnitude of 100 fold. Figure 3b provides the units denied in case of cooperative strategy. The comparative analysis of different mobility models suggests that the profile-based mobility is the worst, followed by random walk, whereas stationary is the best. This is an interesting result because this order is entirely opposite of the order obtained for the competitive strategy. The results show that cooperation has the most positive impact on stationary agents, followed by random walk (semi-mobile) and, then, profile-based (full-mobile). This is, however, not exactly true in the case of restricted cooperation as shown in Figure 3c. In this case, profile-based mobility is better than both stationary and random-walk mobility, whereas the responses for random-walk and stationary modes are almost the same. However, this number or the units denied do not adversely affect the units completed. In fact, the pattern is almost the same as that of units denied, as shown in Figure 4. Moreover, the units completed are higher in number in competitive mode, followed by the cooperative and restricted cooperative mode. This might mean that the competition is much more resource-intensive than cooperation, but without much benefit. Overall, the results reconfirm that cooperation improves the system significantly.
However, in this paper, we focused our analyses only on the variables associated with profile-based mobility. The simulation was, therefore, performed for static values of agents’ density and radius of communication, with only one type of network structure, that is, the small-world network with a beta value of 0.2.
Figure 5, Figure 6 and Figure 7 provide a closer look at the results, for the parameter units denied, of all three strategies (competitive, cooperative, and restricted cooperative) against profile based mobility, in corresponding order. It can be observed that there is no significant difference in terms of units denied for the competitive strategy, when the results presented in Figure 5a–c are compared. The results compared in Figure 5 are for all combinations based on a set of extent values = {3, 6, 9} and a set of scale values = {60, 120, 180}, with population of a 500 agents and small-world networking with the beta value of 0.2. However, when these results are compared with the results of the cooperative strategies presented in Figure 6 and Figure 7, the units denied are approximately ten times more than the cooperative ones. Hence, the cooperation improves the overall situation, as the cooperative strategies greatly reduced the number of units being denied.
Apart from the substantial decrease in the number of units denied, the pattern of restricted cooperation is very similar to the pattern of competitive strategy, as illustrated in Figure 7. We cannot see much difference when extent and scale values are changed. However, this difference is apparent in the cooperative strategy, as illustrated in Figure 6. It can be observed that:
  • There is a definite difference, in terms of units denied, between different combinations of values for extent and scale.
  • It is also observed that the units denied has a gradual increase, as the time, in terms of days, pass by.
The profile-based mobility and a small-world network between the agents represent a configuration closet to a real-life setting. Such a nearest to real-life setting is governed by the extent and scale parameters, where extent represents the number of destinations and scale represents the average distance between the destinations. We argue that these two parameters roughly represent the characteristics of the environment in which social objects (agents) are residing. As the extent increases, the agility or busyness of the environment increases. For example, in smaller towns, people have fewer places to go to; in larger cities they have more places to go. Whereas, as the scale increases, the size of the environment increases (the more average distance between the destinations, the larger the environment). Therefore, in an environment having many social objects, larger values of extent represent more chances of their being closer to each other under a profile-based mobility. Likewise, larger values of scale represent them being farthest from each other. For example, a smaller extent and larger scale will result in extremely dispersed objects as the profile-based mobility gets in action. Similarly, a larger extent and a smaller scale will result in extremely dense objects as the profile based mobility is applied.
As stated before, both cooperative strategies are much more efficient than the competitive one. However, only cooperative strategy is able to differentiate between the value of extent and scale, whereas the other two were unable to do that; this came as a surprise to us. Thus, it is evident that, for the profile-based mobility only, there exists a substantial difference between the outcome for different combinations of extent and scale values. However, even within these results, no combination is an absolute winner. Nevertheless, based on the environment and scenario, the possible situation can be conceptualized and the outcome can be predicted.
The simulation results reveal another drawback of restricted cooperation. That is: the number of units completed in restricted cooperation strategy was less than that of cooperative and competitive strategies. This means that restricted cooperation slows down the system. This is definitely due to less number of service providers. Although, the competitive strategy is similar to the cooperative strategy, in terms of units completed, however, the large number of units denied in the case of competitive strategy suggests that it (competitive strategy) is much more resource-intensive. Therefore, to achieve a similar kind of outcome, we must select the cooperative strategy.

5. Conclusions

From nature to economics, it has been proved that cooperative behavior is also important for societal level growth, in addition to competitive behavior. In this paper, using an agent-based model and simulation, a peer-to-peer resource sharing scenario was taken up to analyze the potential of the social Internet of Things. While accepting competitive behavior as a default behavior to model a resource sharing scenario, a model of cooperative (normal as well as restricted) behavior was also proposed to predict outcomes for different situations.
The simulation results revealed that cooperative strategies for distributed, decentralized, and autonomous resource-sharing mechanisms are much more efficient than competitive strategies. In case of profile-based mobility, it was observed that there exists a substantial difference between the outcome for different combinations of extent and scale values. Therefore, according to the given environment and scenario, the best possible outcomes can be predicted.
Overall, the simulation results revealed that, at least in a peer-to-peer environment, the significance and benefits of social objects are well-grounded and they are consistent with an established understanding of the underlying network structure and mobility patterns of the objects.
For efficient resource (both processing and storage) management, the IoT applications are quickly shifting from centralized cloud computing paradigm to decentralized fog computing paradigm [12]. In this paper, we proposed a model that is about the interaction of social objects and their potential to share resources. A recent paper [17] presented a framework that overlays social and fog links; however, the social layer used is a static graph with connection and does not have any dynamics or behavior. Naturally, in the future, we would like to extend the proposed model so that it can be integrated as the social layer in a fog computing environment.

Author Contributions

Formal analysis, M.S.; Investigation, M.S.; Methodology, K.Z.; Visualization, U.F.; Writing—original draft, K.Z.; Writing—review and editing, M.A. All authors have read and agreed to the published version of the manuscript.


This research received no external funding.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.


  1. Gubbi, J.; Buyya, R.; Marusic, S.; Palaniswami, M. Internet of Things (IoT): A vision, architectural elements, and future directions. Future Gener. Comput. Syst. 2013, 29, 1645–1660. [Google Scholar] [CrossRef] [Green Version]
  2. Park, H.; Kim, H.; Joo, H.; Song, J. Recent advancements in the Internet-of-Things related standards: A oneM2M perspective. ICT Express 2016, 2, 126–129. [Google Scholar] [CrossRef] [Green Version]
  3. Atzori, L.; Iera, A.; Morabito, G.; Nitti, M. The social internet of things (siot)–when social networks meet the internet of things: Concept, architecture and network characterization. Comput. Netw. 2012, 56, 3594–3608. [Google Scholar] [CrossRef]
  4. Atzori, L.; Iera, A.; Morabito, G. Social Internet of Things: Turning Smart Objects into Social Objects to Boost the IoT. Available online: (accessed on 22 March 2021).
  5. Atzori, L.; Iera, A.; Morabito, G. From “smart objects” to “social objects”: The next evolutionary step of the internet of things. IEEE Commun. Mag. 2014, 52, 97–105. [Google Scholar] [CrossRef]
  6. Zia, K.; Muhammad, A.; Saini, D.K. Modeling and Assessment of Resource-sharing Efficiency in Social Internet of Things. In Dependable IoT for Human and Industry: Modeling, Architecting, Implementation; River Publishers: Alsbjergvej, Denmark, 2018; p. 83. [Google Scholar]
  7. Valenzuela, S.; Park, N.; Kee, K.F. Is there social capital in a social network site?: Facebook use and college students’ life satisfaction, trust, and participation1. J. Comput. Mediat. Commun. 2009, 14, 875–901. [Google Scholar] [CrossRef] [Green Version]
  8. Zia, K.; Al Maskari, S.; Saini, D.K.; Muhammad, A.; Farooq, U. A Simulation Model Demonstrating the Impact of Social Aspects on Social Internet of Things. In Proceedings of the 21st International Conference on Information Integration and Web-Based Applications & Services; Association for Computing Machinery: New York, NY, USA, 2019; pp. 202–211. [Google Scholar] [CrossRef]
  9. Helbing, D. Agent-based modeling. In Social Self-Organization; Springer: Berlin/Heidelberg, Germany, 2012; pp. 25–70. [Google Scholar]
  10. Caram, L.F.; Caiafa, C.F.; Ausloos, M.; Proto, A.N. Cooperative peer-to-peer multiagent-based systems. Phys. Rev. E 2015, 92, 022805. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  11. Loo, A.W.S. Peer-To-Peer Computing; Springer: Berlin/Heidelberg, Germany, 2007. [Google Scholar]
  12. Atlam, H.F.; Walters, R.J.; Wills, G.B. Fog computing and the internet of things: A review. Big Data Cognit. Comput. 2018, 2, 10. [Google Scholar] [CrossRef] [Green Version]
  13. Naha, R.K.; Garg, S.; Georgakopoulos, D.; Jayaraman, P.P.; Gao, L.; Xiang, Y.; Ranjan, R. Fog computing: Survey of trends, architectures, requirements, and research directions. IEEE Access 2018, 6, 47980–48009. [Google Scholar] [CrossRef]
  14. Cisco Annual Internet Report (2018–2023) White Paper. 2020. Available online: (accessed on 25 June 2020).
  15. IoT Platforms: Enabling the Internet of Things. 2016. Available online: (accessed on 27 July 2020).
  16. White Paper for Opening up Huawei IoT Capabilitles. 2017. Available online: (accessed on 4 January 2017).
  17. Khelloufi, A.; Ning, H.; Dhelim, S.; Qiu, T.; Ma, J.; Huang, R.; Atzori, L. A Social Relationships Based Service Recommendation System For SIoT Devices. IEEE Internet Things J. 2020, 8, 1859–1870. [Google Scholar] [CrossRef]
  18. Gupta, B.B.; Perez, G.M.; Agrawal, D.P.; Gupta, D. Handbook of Computer Networks and Cyber Security; Springer: Berlin/Heidelberg, Germany, 2020. [Google Scholar]
  19. Popovskyy, V.; Popovska, K. Analysis of content replication mechanism in random search in peer-to-peer networks. Inf. Telecommun. Sci. 2017, 23–26. [Google Scholar] [CrossRef] [Green Version]
  20. Tetarave, S.K.; Tripathy, S. PJ-Sec: Secure node joining in mobile P2P networks. CCF Trans. Pervasive Comput. Interact. 2020, 3, 13–24. [Google Scholar] [CrossRef]
  21. Navimipour, N.J.; Milani, F.S. A comprehensive study of the resource discovery techniques in Peer-to-Peer networks. Peer Peer Netw. Appl. 2015, 8, 474–492. [Google Scholar] [CrossRef]
  22. Pticek, M.; Podobnik, V.; Jezic, G. Beyond the Internet of Things: The Social Networking of Machines. Int. J. Distrib. Sens. Netw. 2016, 12, 8178417. [Google Scholar] [CrossRef] [Green Version]
  23. Bartodziej, C.J. The Concept Industry 4.0. In The Concept Industry 4.0; Springer: Berlin/Heidelberg, Germany, 2017; pp. 27–50. [Google Scholar]
  24. Oztemel, E.; Gursev, S. Literature review of Industry 4.0 and related technologies. J. Intell. Manuf. 2020, 31, 127–182. [Google Scholar] [CrossRef]
  25. Camarinha-Matos, L.M.; Fornasiero, R.; Afsarmanesh, H. Collaborative networks as a core enabler of industry 4.0. In Working Conference on Virtual Enterprises; Springer: Berlin/Heidelberg, Germany, 2017; pp. 3–17. [Google Scholar]
  26. Kehal, M. Business Analytics: Through SIoT and SIoV. In Data Analytics in Marketing, Entrepreneurship, and Innovation; Auerbach Publications: Boca Raton, FL, USA, 2021; pp. 1–14. [Google Scholar]
  27. Zia, K.; Shafi, M.; Farooq, U. Improving recommendation accuracy using social network of owners in social internet of vehicles. Future Internet 2020, 12, 69. [Google Scholar] [CrossRef]
  28. Rehman, A.U.; Naqvi, R.A.; Rehman, A.; Paul, A.; Sadiq, M.T.; Hussain, D. A trustworthy siot aware mechanism as an enabler for citizen services in smart cities. Electronics 2020, 9, 918. [Google Scholar] [CrossRef]
  29. Cervantes, M.; Ramani, R.; Worthy, P.; Weigel, J.; Viller, S.; Matthews, B. Could the Inherent Nature of the Internet of Things Inhibit Person-to-Person Connection? In Proceedings of the 2016 ACM Conference Companion Publication on Designing Interactive Systems; ACM: New York, NY, USA, 2016; pp. 177–180. [Google Scholar]
  30. Worthy, P.; Matthews, B.; Viller, S. Trust me: Doubts and concerns living with the Internet of Things. In Proceedings of the 2016 ACM Conference on Designing Interactive Systems; ACM: New York, NY, USA, 2016; pp. 427–434. [Google Scholar]
  31. Jayasinghe, U.; Lee, H.W.; Lee, G.M. A computational model to evaluate honesty in social internet of things. In Proceedings of the Symposium on Applied Computing; ACM: New York, NY, USA, 2017; pp. 1830–1835. [Google Scholar]
  32. Anjomshoa, F.; Aloqaily, M.; Kantarci, B.; Erol-Kantarci, M.; Schuckers, S. Social behaviometrics for personalized devices in the internet of things era. IEEE Access 2017, 5, 12199–12213. [Google Scholar] [CrossRef]
  33. Atzori, L.; Iera, A.; Morabito, G. Siot: Giving a social structure to the internet of things. IEEE Commun. Lett. 2011, 15, 1193–1195. [Google Scholar] [CrossRef]
  34. Savaglio, C.; Ganzha, M.; Paprzycki, M.; Bădică, C.; Ivanović, M.; Fortino, G. Agent-based Internet of Things: State-of-the-art and research challenges. Future Gener. Comput. Syst. 2020, 102, 1038–1053. [Google Scholar] [CrossRef]
  35. Cicirelli, F.; Guerrieri, A.; Spezzano, G.; Vinci, A. An edge-based platform for dynamic smart city applications. Future Gener. Comput. Syst. 2017, 76, 106–118. [Google Scholar] [CrossRef]
  36. Nguyen, H.L.; Jung, J.E. SocioScope: A framework for understanding Internet of Social Knowledge. Future Gener. Comput. Syst. 2018, 83, 358–365. [Google Scholar] [CrossRef]
  37. Romero, D.; Wuest, T.; Stahre, J.; Gorecky, D. Social factory architecture: Social networking services and production scenarios through the social internet of things, services and people for the social operator 4.0. In IFIP International Conference on Advances in Production Management Systems; Springer: Berlin/Heidelberg, Germany, 2017; pp. 265–273. [Google Scholar]
  38. Lippi, M.; Mamei, M.; Mariani, S.; Zambonelli, F. An argumentation-based perspective over the social IoT. IEEE Internet Things J. 2017, 5, 2537–2547. [Google Scholar] [CrossRef] [Green Version]
  39. Fortino, G.; Russo, W.; Savaglio, C.; Viroli, M.; Zhou, M. Opportunistic cyberphysical services: A novel paradigm for the future Internet of Things. In Proceedings of the 2018 IEEE 4th World Forum on Internet of Things (WF-IoT), Singapore, 5–8 February 2018; pp. 488–492. [Google Scholar]
  40. Casadei, R.; Fortino, G.; Pianini, D.; Russo, W.; Savaglio, C.; Viroli, M. A development approach for collective opportunistic Edge-of-Things services. Inf. Sci. 2019, 498, 154–169. [Google Scholar] [CrossRef]
  41. Casadei, R.; Fortino, G.; Pianini, D.; Russo, W.; Savaglio, C.; Viroli, M. Modelling and simulation of opportunistic IoT services with aggregate computing. Future Gener. Comput. Syst. 2019, 91, 252–262. [Google Scholar] [CrossRef]
  42. Hauert, C. Cooperation, collectives formation and specialization. Adv. Complex Syst. 2006, 9, 315–335. [Google Scholar] [CrossRef]
  43. Dorigo, M.; Birattari, M.; Stutzle, T. Ant colony optimization. IEEE Comput. Intell. Mag. 2006, 1, 28–39. [Google Scholar] [CrossRef] [Green Version]
  44. Fehr, E.; Schmidt, K.M. A theory of fairness, competition, and cooperation. Q. J. Econ. 1999, 114, 817–868. [Google Scholar] [CrossRef]
  45. Barreira da Silva Rocha, A.; Laruelle, A. Evolution of cooperation in the snowdrift game with heterogeneous population. Adv. Complex Syst. 2013, 16, 1350036. [Google Scholar] [CrossRef]
  46. Schweitzer, F.; Behera, L. Optimal migration promotes the outbreak of cooperation in heterogeneous populations. Adv. Complex Syst. 2012, 15, 1250059. [Google Scholar] [CrossRef] [Green Version]
  47. Koponen, I.T.; Nousiainen, M. Formation of reciprocal appreciation patterns in small groups: An agent-based model. Complex Adapt. Syst. Model. 2016, 4, 24. [Google Scholar] [CrossRef] [Green Version]
  48. Dhelim, S.; Ning, H.; Zhu, T. STLF: Spatial-temporal-logical knowledge representation and object mapping framework. In Proceedings of the 2016 IEEE International Conference on Systems, Man, and Cybernetics (SMC), Budapest, Hungary, 9–12 October 2016; pp. 001550–001554. [Google Scholar]
  49. Gilbert, N. Agent-Based Models; Sage Publications, Incorporated: Thousand Oaks, CA, USA, 2019; Volume 153. [Google Scholar]
  50. Grimm, V.; Polhill, G.; Touza, J. Documenting social simulation models: The ODD protocol as a standard. In Simulating Social Complexity; Springer: Berlin/Heidelberg, Germany, 2017; pp. 349–365. [Google Scholar]
  51. Wilensky, U. NetLogo (and NetLogo User Manual). Available online: (accessed on 22 March 2021).
  52. Centola, D.; Macy, M. Complex contagions and the weakness of long ties. Am. J. Sociol. 2007, 113, 702–734. [Google Scholar] [CrossRef] [Green Version]
  53. Watts, D.J.; Strogatz, S.H. Collective dynamics of’small-world’networks. Nature 1998, 393, 440. [Google Scholar] [CrossRef] [PubMed]
  54. Wilensky, U.; Rand, W. An Introduction to Agent-Based Modeling: Modeling Natural, Social, and Engineered Complex Systems with NetLogo; MIT Press: Cambridge, MA, USA, 2015. [Google Scholar]
  55. Zia, K.; Muhammad, A.; Saini, D.K. Socially aware peers for futuristic web of things. In Proceedings of the 2017 9th IEEE International Conference on Intelligent Data Acquisition and Advanced Computing Systems: Technology and Applications (IDAACS), Bucharest, Romania, 21–23 September 2017; Volume 2, pp. 579–583. [Google Scholar]
  56. Zia, K.; Saini, D.K.; Farooq, U.; Ferscha, A. Web of social things: Socially-influenced interaction modeling. In Proceedings of the 15th International Conference on Advances in Mobile Computing & Multimedia, Salzburg, Austria, 4–6 December 2017; pp. 123–130. [Google Scholar]
Figure 1. Agent-based model of peers in competitive mode. current_time is iteration (a minute in a day). current_service is one of the four possible services. psp contains all other agents in the neighborhood [strategy “mesh” (whole space) or “regular” (only neighborhood) or “small-world” (in a proximity defined by neighborhood and beta value)] who have completed the current_service (evidenced by CSC table). Adapted from [8].
Figure 1. Agent-based model of peers in competitive mode. current_time is iteration (a minute in a day). current_service is one of the four possible services. psp contains all other agents in the neighborhood [strategy “mesh” (whole space) or “regular” (only neighborhood) or “small-world” (in a proximity defined by neighborhood and beta value)] who have completed the current_service (evidenced by CSC table). Adapted from [8].
Iot 02 00010 g001
Figure 2. Agent-Based Model of Peers in Cooperative Mode, adapted from [8].
Figure 2. Agent-Based Model of Peers in Cooperative Mode, adapted from [8].
Iot 02 00010 g002
Figure 3. Comparison of units denied: (a) competitive strategy; (b) cooperative strategy; (c) competitive strategy in restricted mode.
Figure 3. Comparison of units denied: (a) competitive strategy; (b) cooperative strategy; (c) competitive strategy in restricted mode.
Iot 02 00010 g003
Figure 4. Comparison of units completed: (a) competitive strategy; (b) cooperative strategy; (c) competitive strategy in restricted mode.
Figure 4. Comparison of units completed: (a) competitive strategy; (b) cooperative strategy; (c) competitive strategy in restricted mode.
Iot 02 00010 g004
Figure 5. Units denied in case of competitive strategy: (a) extent = 3; (b) extent = 6; (c) extent = 9.
Figure 5. Units denied in case of competitive strategy: (a) extent = 3; (b) extent = 6; (c) extent = 9.
Iot 02 00010 g005
Figure 6. Units denied in case of cooperative strategy: (a) extent = 3; (b) extent = 6; (c) extent = 9.
Figure 6. Units denied in case of cooperative strategy: (a) extent = 3; (b) extent = 6; (c) extent = 9.
Iot 02 00010 g006
Figure 7. Units denied in case of restricted cooperative strategy: (a) extent = 3; (b) extent = 6; (c) extent = 9.
Figure 7. Units denied in case of restricted cooperative strategy: (a) extent = 3; (b) extent = 6; (c) extent = 9.
Iot 02 00010 g007
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Zia, K.; Farooq, U.; Shafi, M.; Arshad, M. An Agent-Based Model of Task-Allocation and Resource-Sharing for Social Internet of Things. IoT 2021, 2, 187-204.

AMA Style

Zia K, Farooq U, Shafi M, Arshad M. An Agent-Based Model of Task-Allocation and Resource-Sharing for Social Internet of Things. IoT. 2021; 2(1):187-204.

Chicago/Turabian Style

Zia, Kashif, Umar Farooq, Muhammad Shafi, and Muhammad Arshad. 2021. "An Agent-Based Model of Task-Allocation and Resource-Sharing for Social Internet of Things" IoT 2, no. 1: 187-204.

Article Metrics

Back to TopTop