I know several people have chimed in and said that it is the block size that is limiting the transactions per second, but that doesn't make sense to me, I don't see, nor understand, what block size has to do with transactions per second...
A block can hold no more than 1 MB of transactions. This sets the network's transaction speed limit.
A block is generated once every 10 minutes on average. We can calculate the block chain's write speed with:
w = s * g
where w is write speed MB/hour, s is block size limit in megabytes (1 MB/block), and g is the rate of block generation per hour (6 blocks/hour).
Plugging in the value yields:
w = 1 MB/block * 6 blocks/hour = 6 MB/hour
Converting to bytes/second, that's:
6 MB/hour * (1 hour/60 minutes) * (1 minute/60 seconds) * (1,000,000 bytes/1 MB) = 1,700 bytes/second
In other words, think of the blockchain as a hard drive. We can write to this hard drive at a rate of 1,700 bytes/second.
Even if we develop faster computers, we can't write data faster than this because the network rejects any block larger than 1 MB. We need to make some allowances for SegWit, but for now, let's keep things simple.
A one-input, one-output Alice-Pays-Bob transaction requires ~ 200 bytes. This is the absolute best case. We can, therefore, obtain an upper bound on the transaction rate using:
v = w / z
where v is the maximum transaction volume, w is the write speed calculated above (1,700 bytes/second), and z is the average size of a transaction (200 bytes/transaction).
Plugging in the numbers:
v = 1,700 bytes/second * (1 transaction / 200 bytes) = 8 transactions/second
The answer to my question should be something like verification of sufficient funds per transaction input address takes 0.1 seconds, or as a whole verification of each transaction takes 0.3 seconds.
The network might appear to have a limit based on hardware or validation, but it does not. At least not directly.
As to why we should limit the block chain's write speed in the first place, the answer has to do with network security. Increasing write speed means:
- data flows through the network at a higher rate;
- more data must be stored by every node;
- more transactions must be validated by every node.
Every node sends and receives every block, and every block must be stored. Increasing the blockchain write speed means that every node pays the price. Some won't be able to keep up, regardless of write speed.
Transaction validation is a resource hog due to signature validation and UTXO set manipulation. Storage space and bandwidth are also considerations, but less resource-intensive than validation.
Now, if you're asking why we have a 1 MB limit given XXX computer has such-and-such technical capabilities, that's the realm of the Never Ending Debate. Calculations have been done and simulations have been reported. They are not hard to find. They are, however, hard to believe given their wildly-differing claims and underlying assumptions.
The best thing I can recommend is to download a copy of Bitcoin Core 0.16.0 and try syncing a node from scratch. Report back when you're done.
The write speed limit we see is a compromise between inclusivity (more people using bitcoin) and security (difficulty of double-spending attacks). The limit may not have been set correctly, but figuring out where (or even how) to set it is exceedingly difficult. Not because of lack of ideas, but because of too many and lack of widely-accepted selection criteria.
Thank you for your answer, however, I am more interested in the technical details of the bottleneck, I have updated my question with some examples of what I believe the bottle neck might be – Jeffrey L. Roberts – 2018-06-01T23:58:16.160
No, there is a hardcoded limit to the size of blocks, and blocks above that size are simply rejected by nodes that validate them. The reasons for why that limit exist are already answered in several other questions. – Pieter Wuille – 2018-06-02T00:02:02.737
ok, I understand that, but that doesn't tell me why bitcoind doesn't process more than 7 transactions a second... – Jeffrey L. Roberts – 2018-06-05T04:31:22.943
No more than a certain number of transactions can fit in a block, which are found, on average, every 10 minutes. Since "processing a transaction" means including it in a block, the bottleneck is in the number of transactions that can be included in a block and the amount of time required to produce a block. When you take the maximum number of transactions that can fit in a block and divide that by the average time to find a block, then you get a number that is around 7 transactions per second. – Andrew Chow – 2018-06-05T04:36:44.833
So what you are telling me, is that if 10 transactions get broadcast in one second, then bitcoind can include them in the next block within a second? What if a 100 transactions were broadcast in one second? – Jeffrey L. Roberts – 2018-06-05T11:18:27.843
1@JeffreyL.Roberts blocks get mined every 10 minutes. A typical 1-input-2-outputs transaction takes around 250 bytes. Each block has 1MB room for transactions so it can take around 4000. 4000/10minutes = 6.67/sec – Mike D – 2018-06-05T13:08:50.333
hrmmm, my last comment, my apologies, but to me, that is the average amount of transactions per second, not the transactions per second rate – Jeffrey L. Roberts – 2018-06-05T14:30:01.823
1The transactions per second rate that is commonly cited is exactly that: the average amount of transactions per second. – Andrew Chow – 2018-06-05T23:24:42.780
So what is the max? Im guessing hardware plays a role in that, but there should be a range, the range ive found is 3.3 to 7 transactions per second, now back to my question, what is the limiting factor or resource hog that limits bitcoind to 7 transactions per second? – Jeffrey L. Roberts – 2018-06-05T23:31:36.820
As has been stated multiple times in this answer, the limiting factor is the number of transactions that can fit in a block. This is completely unrelated to bitcoind, it is related to Bitcoin's consensus rules. bitcoind itself can verify many thousands of transactions per second with the limiting factor being your hardware. But for the network as a whole, the limit is in the consensus rules. – Andrew Chow – 2018-06-06T05:32:14.353
1What exactly do you not understand about the answer? You keep asking the same question over and over again. Please clarify what you don't understand about the answer. – Andrew Chow – 2018-06-06T05:32:41.167
I think something is getting lost in translation here, you keep offering me the average number of transactions per second, and I am looking for the limiting factor of the actual number of transactions per second... – Jeffrey L. Roberts – 2018-06-07T03:15:14.563
The number that you have cited (which I assume is what you believe is the "actual number of transactions per second") is actually the average number of transactions per second. The actual number of transactions per second that bitcoind can handle is very large, on the order of thousands of transactions per second and varies highly due to hardware. – Andrew Chow – 2018-06-07T09:45:27.300
I know comments are not for thank-you but, I wanted you to know I upvoted your answer anyway. – Willtech – 2018-06-07T10:29:10.697