Performance Evaluation of Blockchains in the Internet of Things

The idea of blockchains technology (BT) in the internet of things (IoT) is to allow the physical things to trust in the transactions held within the IoT network. The BT is a distributed, decentralized, publicly shared its digital ledger and secured technology to eternally record the transactions across the shared database. The BT in IoT can be called Trust Machine to eliminate the intermediates and enables the physical things to trust with each other. This research evaluates the performance of BT in IoT. The simulated results are tested and can be used in the sustainable development of the integration of BT and IoT.<br>


INTRODUCTION
The internet of things (IoT) enables the physical things to connect, communicate and exchange information without a human to human or human to machine interaction [1].The blockchains technology (BT) is a growing chain of blocks with the cryptographic hash to eternally record the transactions and store in public database.The IoT and BT both technologies are presumable emerging terms and the framework to integrate these technologies can generate new opportunities in the area of communication security and reliability among internet of physical things [2].But scalability is a big challenge to integrate both the technologies together because of a huge number of physical connected things in the heterogeneous network [3][4][5][6].
The BT in IoT is a novel technology that acts with decentralized, distributed, public and real-time ledger to store transactions among IoT nodes [7].A blockchain is a series of blocks, each block is linked to its previous blocks [8].Every block has a cryptographic hash code, previous block hash, and its data.The transactions in BT are the basic units that are used to transfer data between IoT nodes.The IoT nodes are different kind of physical but smart devices with embedded sensors, actuators, programs and able to communicate with other IoT nodes [9].

THE ROLE OF BT IN IOT
The role of BT in IoT is to provide a procedure to process secured records of data through IoT nodes represented on Figure 1.BT is a secured technology that can be used publicly and openly [10][11][12][13][14].The IoT requires this kind of technology to communicate securely among the IoT nodes [15][16][17].The transactions in Electronic copy available at: https://ssrn.com/abstract=3684666

RESULTS AND ANALYSIS
In BT is a series of blocks.The size of a block (BS) in blockchain can be obtained by the following formula [8]: BS (in MB) = HS (in Bytes) + TS (in Bytes) * No of transactions in that block. ( Where HS is the size of the header.The Total Mining energy (Te) can be calculated by the sum of all connected IoT nodes mining energy (E): (2) Time (t) taken by a block between interconnected IoT nodes with their bandwidth Bw: where Bw(i,j) is the bandwidth between the IoT nodes i,j.The framework width (Fw) can be obtained by The hash is the crypto code of the previous block (Hc) that is assigned to every block in the blockchain.The block occurrence (Bo) can be obtained by Bo=Te/Hc. ( The transactions per second (Ts) held in the blockchain can be obtained by the formula: Ts=Bo * No of transactions in that block (6) The fork in blockchain can happen if the miners received the blocks at the same time.The probability of blockchain fork P(F) can be calculated by the formula: Electronic copy available at: https://ssrn.com/abstract=3684666 Comput.Sci.Inf.Technol.


Performance evaluation of blockchains in the internet of things… (Tanweer Alam)

95
Consider the newly created block BN that is referenced by two previously created blocks.The BN is placed between these two blocks.Consider that the block BN is verified by the miners, the time BN(t) is represented the verification time calculated by the Poisson process µ [23][24][25].Suppose α be the time taken by the IoT node to compute the transaction process to the fog network.So, the total time taken by each transaction to be visible on the network is α+t [9].Consider that N is the total number of unverified blocks [26][27].The probability of BN in the blockchain of the IoT-Fog framework is calculated by the following formula.P(BN) = N / (N + μα) (8) Consider the 5 IoT nodes (Figure 2) connected with the P2P network with the mining energy 500,1000, 300, 700, and 1500 respectively.They are able to do transactions in the proposed framework.Suppose the size of the header is 100 bytes and the size of the transaction is 500 bytes.The IoT nodes in the framework are five.Using (1), we have calculated the block size.BS (in MB) = HS (in Byes) + TS (in Bytes) * No of transactions in that block BS=100+500*5=2600 MB Now, according to (3), we have to calculate the bandwidth of the framework as shown in Table 1.The IoT-Fog framework is tested using 5 local IoT nodes and 2 remote IoT nodes.The NoSQL database software is used to store the records fetched from blockchain in the fogging by the tool named OPENSHIFT platform.Cloud is created by Amazon, bandwidth of the system is shown in Figure 3.The FogSim software is used to connect the IoT devices to the fogging.Performance evaluation of IoT nodes in the IoT-Fog is represented in Figure 4.The results are found in Table 2.


ISSN: 2722-3221 Comput.Sci.Inf.Technol., Vol. 1, No. 2, July 2020: 93 -97 94 BT could be traced and explored through anyone who is authenticated to communicate within the IoT.The BT in IoT may help to improve communication security [18'].The major benefits of BT with IoT are:  Develop trust among IoT public nodes and minify the risk of collisions [19-21],  Minify the processing costs through direct communication without the third parties [22],  speed up the transactions in real time.

Figure 2 .
Figure 2. IoT Nodes connected in the P2P network

Figure 3 .
Figure 3. Bandwidth of the system

Figure 4 .
Figure 4. Performance evaluation of IoT nodes in the IoT-Fog

Table 1 .
Bandwidth in the framework device by device