<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <article-id pub-id-type="doi">10.3390/s21010047</article-id>
      <title-group>
        <article-title>Bitcoin: A Queuing Analytical Approach</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Peter Vesely</string-name>
          <email>Peter.Vesely@fm.uniba.sk</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Sophia Skoda</string-name>
          <xref ref-type="aff" rid="aff2">2</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Ievgen Kolomiiets</string-name>
          <xref ref-type="aff" rid="aff2">2</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Benjamin Stöberl</string-name>
          <xref ref-type="aff" rid="aff2">2</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Tetiana Klynina</string-name>
          <email>tklynina@gmail.com</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Comenius University in Bratislava, Faculty of Management</institution>
          ,
          <addr-line>820 05 Bratislava</addr-line>
          ,
          <country country="SK">Slovakia</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>National Aviation University</institution>
          ,
          <addr-line>Liubomyr Huzar Avenue 1, Kyiv city, 03058</addr-line>
          ,
          <country country="UA">Ukraine</country>
        </aff>
        <aff id="aff2">
          <label>2</label>
          <institution>University of Vienna, Faculty of Business, Economics &amp; Statistics</institution>
          ,
          <addr-line>Vienna 109</addr-line>
          ,
          <country country="AT">Austria</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2021</year>
      </pub-date>
      <volume>21</volume>
      <issue>1</issue>
      <fpage>391</fpage>
      <lpage>398</lpage>
      <abstract>
        <p>The block chain is a shared public ledger on which the entire Bitcoin network relies. All established transactions are contained within block chain. Bitcoin wallets to calculate their spendable balance is allowed. New transactions can be verified thereby ensuring. They are essentially owned by the spender. The integrity and the chronological order of the block chain are enforced with cryptography. A transaction is a transfer of value between Bitcoin wallets that gets included in the block chain. Bitcoin wallets keep a secret piece of data called private key, which is used to sign transactions, providing a mathematical proof that they have come from the owner of the wallet. The signature also prevents the transaction from being altered by anybody once it has been issued. Queuing analytical approach, bitcoin, queueing system, network, blockchain, instant payments All transactions are broadcast to the network and usually begin to be confirmed within 10 to 20 minutes, through a process called “mining”. Mining is a distributed consensus system that is used to confirm pending transactions by including them in the block chain. It enforces a chronological order in the block chain, protects the neutrality of the network, and allows different computers to agree on the state of the system. Mining also creates the equivalent of a competitive lottery that prevents any individual from simply adding new blocks consecutively to the block chain [1-4].</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>2021 Copyright for this paper by its authors.</p>
      <p>The above figure shows such a blockchain queuing system [6-9]. There are several factors that need
to be discussed. There is an arrival process in which transactions arrive at the blockchain system
according to a Poisson process with arrival rate λ. Each transaction must first enter and queue at a
waiting room of infinite size. This is the first stage of service called “block generation” [10].
Subsequently, the block with this transaction is built into the blockchain. This is the second stage of
service called “blockchain building”. Therefore, the mining process of transactions include two stages
of batch services.</p>
      <p>In the blockchain system, we assume that the block-generation times in the first stage are i.i.d and
exponential with service rate μ2, the blockchain-building times [11] in the second stage are i.i.d and
exponential with the service rate μ1.</p>
      <p>The block-generation discipline means that a block can consist of several transactions. The maximus
is b transactions.</p>
      <p>A maximum block size is limited in order to avoid spam attack.</p>
    </sec>
    <sec id="sec-2">
      <title>2. Comparison of M/M/1-Models and M/G/1-Models</title>
      <p>First, a distinction between M/M/1-models and M/G/1-models is made, as this is significant for
further calculations. The simple M/M/1-models were usually used in the course; however, this model
type cannot be applied for Bitcoins transactions.</p>
      <p>A M/M/1-model [12] is one in which both, the inter-arrival time and the service time are
exponentially distributed. However, in a M/G/1-model only the inter-arrival time is exponentially
distributed and the service time is generally distributed. This means that it is a given distribution.</p>
      <p>For the scalability of Bitcoins transactions this distinction is crucial as the transactions are processed
in blocks and the service time is given by 10 minutes and one block has a size of 1 megabyte. The 10
minutes are stated by Bitcoins. The reason for this is that the miners need to solve mathematical
examples [13-16] to be able to add a new block to the blockchain. The creators of the examples of
Bitcoins set the mathematics problems in a way that it always takes approximately 10 minutes to solve
it. It is not exactly 10 minutes but the deviation here is very low, so we can assume that the 10 minutes
are almost steady. And new blocks need to be created in order to make sure, that the blockchain [17,
18] keeps growing, as a steady growth ensures that manipulations are kept to a very low level.</p>
    </sec>
    <sec id="sec-3">
      <title>3. Queuing Analysis</title>
      <p>All the input data needed for queuing analysis was retrieved from www.blockchain.com. The
website provides real data on bitcoin. The time frame observed was the week between 29th of October
2018 to the 4th of November 2018.</p>
      <p>3.1.</p>
    </sec>
    <sec id="sec-4">
      <title>Calculations – Formula Inputs</title>
      <p>Arrival Rate (λ)</p>
      <p>First, the input data for the formulas must be generated. For the arrival rate λ, the average incoming
transaction requests per second of every day in the respective week were retrieved. Then, the average
incoming transaction requests per second were calculated. This number stays the same for both a block
size of 1 MB (standard case) and 5 MB (optimization case).
The formula for the service rate is
Service Rate (μ)</p>
      <p>To get to the service rate μ, we needed to define the service time first. We defined the service time
as the average block mining time. The bitcoin system acts a batch service system, processing on batch
roughly every ten minutes, when a new block is mined and added to the blockchain. One block contains
up to 2020 transactions (1 MB block size) or 10101 transactions (5 MB block size).</p>
      <p>To simplify, we took 2020 and 10101 transactions as fix input parameters. The average block mining
time was also retrieved from real data:
Block Size 1 MB:
Block Size 1 MB:
λ
μ
λ
μ</p>
      <p>While the result for the number in the queue (4455,90 transactions) pretty much hits the observed
result (4652,29 transactions) of customers in the queue (MemPool Transactions), the results for the wait
in the queue and wait in the system aren’t that good. One possible reason is the fact that bitcoin is a
batch system that processes a batch of 2020 (1 MB block size) every 10 minutes. Our model does not
really reflect this batch system. Also, the processing order is not only dependent on the time of the
transaction request. Other factors, like the transaction fee offered to the minors and the transaction size
play an important role when it is decided if a transaction is added to a block. Further, not every
transaction is even added to a block, even the block is still “open” (mining not finished). To sum up,
our model is too simple for the real-world complexity of bitcoin.</p>
      <p>3.3.</p>
    </sec>
    <sec id="sec-5">
      <title>Calculations – Block Size of 5 MB</title>
      <p>When comparing the Transactions in the queue for a block size of 1 MB vs the block size of 5 MB,
a massive improvement can be observed (Figure 2). Due to the increased amount of transactions in each
block, the Transactions in the Queue ( ) grow slower with increasing arrival rate for a block size
of 5 MB. The improvement becomes visible at a λ of approximately 1,8 and becomes larger from
there on. Nevertheless, it has to mentioned that our improvement only leads to a shift of the curve
and does not eliminate the queuing problem entirely. Also, it has to be mentioned that an
increasement of the blocksize by the factor 5 eventually leads to a larger blockchain. The current
bitcoin blockchain has a size of approximately 200 GB. Increasing the block size to 5 Megabyte
would mean a blockchain of approximately 1000 GB. This could lead to problems, as the entire
blockchain is stored on every participant’s personal computer. Not every participant has 1000
GB of free storage available.</p>
      <p>e
u
e
u
Q</p>
      <p>Development of Queue with Rising Arrival Rate
50 000
0 0,6 1,2 1,8 2,4 3 3,6 4,2 4,8 5,4 6 6,6 7,2 7,8 8,4 9</p>
      <p>λ Arrival Rate</p>
      <sec id="sec-5-1">
        <title>Block Size 1 MB</title>
      </sec>
      <sec id="sec-5-2">
        <title>Block Size 5 MB</title>
      </sec>
    </sec>
    <sec id="sec-6">
      <title>4. Future Optimization</title>
      <p>In this chapter we want to show which possibilities exist in the real world for future optimizations
in the Bitcoin network. Fork mostly means a kind of software upgrade or update which is done in such
a way that it can be backward compatible or cannot be backward compatible. Forks produce a different
version of the blockchain, leaving two blockchains to run simultaneously on different parts of the
network. In the realm of cryptocurrencies or blockchains, there are mainly two types of forks [19, 20]:
Soft forks and hard forks. The Bitcoin protocol itself has not undergone a non-contentious hard fork yet
but it has undergone many contentious hard forks like Bitcoin Cash.</p>
      <sec id="sec-6-1">
        <title>The example of Bitcoin Cash hard fork:</title>
        <p>The difference from the original Bitcoin is that there is a higher transaction speed due to a block size
increase from 1 to 5 MB. This means also that it is less decentralized. So, the question is what actually
happened. After the Hard Fork, Bitcoin Cash became a new, separate currency. Everyone who had
Bitcoins before the hard fork received the same amount in his Bitcoin Cash wallet. This was on 1st
August 2017. Hard forks are a feasible way of updating the rules of cryptocurrencies and Bitcoin in
particular, so it is definitely a way to upgrade the Bitcoin Network.</p>
      </sec>
    </sec>
    <sec id="sec-7">
      <title>5. References</title>
      <p>[1] “Bitcoin Block Time Chart.” BitInfoCharts. Accessed January 19, 2019. https://bitinfocharts.com/.
[2] “Blockchain Size.” Accessed, 2019. https://www.blockchain.com/charts/blocks-size.
[3] Kasahara, Shoji, Jun Kawahara. “Effect of Bitcoin Fee on Transaction-Confirmation Process.”,
March 31, 2016. http://arxiv.org/abs/1604.00103.</p>
      <sec id="sec-7-1">
        <title>Springer, 2017.</title>
        <p>Springer. 2021, pp. 545-557.
[4] Kawase, Yoshiaki, Shoji Kasahara. “Transaction-Confirmation Time for Bitcoin: A Queueing</p>
        <p>Analytical Approach to Blockchain Mechanism.” In Queueing Theory and Network Applications,
[5] Fedushko S., Ustyianovych T. Operational Intelligence Software Concepts for Continuous
Healthcare Monitoring and Consolidated Data Storage Ecosystem. Advances in Computer Science
for Engineering and Education III. Advances in Intelligent Systems and Computing, vol 1247.
[6] Li, Quan-Lin, Jing-Yu Ma, and Yan-Xia Chang. “Blockchain Queueing Theory⋆,” 17.
[7] “Lightning Network.” Accessed January 30, 2019. https://lightning.network/.</p>
      </sec>
    </sec>
  </body>
  <back>
    <ref-list />
  </back>
</article>