Skip to main content
added 893 characters in body
Source Link
Wapac
  • 1.1k
  • 7
  • 16

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expandhttps://blockchair.com/bitcoin/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a

Size = 1158.1,158,038 KB Virtual size = 999 vKBbytes Weight units = 3992.4933,992,825 KWUWU 

WhatThere is also something called virtual size (VS) then?. This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

AS = 11581,158,038 KBbytes = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.4933,992,825 KWUWU = nWD * 4 weight units + WD weight units 

This implies that it is not correct to think that a block of size 1.1 MB is composed of 1,000,000 bytes of nWD and the rest is WD. That wouldn't work because the weight of 1,000,000 nWD bytes would already be 4,000,000 WU and therefore if we added the weight of WD to it, we would be over the limit. That is not possible.

So, if we know AS = 1,158,038 KB then it is rather that there are 944,929 bytes of nWD with weight of 3,779,716 WU and the rest is 213,109 bytes of WD with weight 213,109. This makes the total weight of the block 3,779,716 + 213,109 = 3,992,825 WU.

We can now calculate VS:

VS = nWD vBytes + WD/4 vBytes = 944,929 + 213,109 / 4 = 998,206.25 vBytes 

Virtual size (VS) thus cannot be greater than 1,000,000 vBytes, so this is what is meant if someone says that the new block size is still limited by 1 MB - they actually mean 1 million of vBytes.

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

This implies that it is not correct to think that a block of size 1.1 MB is composed of 1,000,000 bytes of nWD and the rest is WD. That wouldn't work because the weight of 1,000,000 nWD bytes would already be 4,000,000 WU and therefore if we added the weight of WD to it, we would be over the limit. That is not possible.

Have a look: https://blockchair.com/bitcoin/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a

Size = 1,158,038 bytes Weight units = 3,992,825 WU 

There is also something called virtual size (VS). This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

AS = 1,158,038 bytes = nWD bytes + WD bytes BW = 3,992,825 WU = nWD * 4 weight units + WD weight units 

This implies that it is not correct to think that a block of size 1.1 MB is composed of 1,000,000 bytes of nWD and the rest is WD. That wouldn't work because the weight of 1,000,000 nWD bytes would already be 4,000,000 WU and therefore if we added the weight of WD to it, we would be over the limit. That is not possible.

So, if we know AS = 1,158,038 KB then it is rather that there are 944,929 bytes of nWD with weight of 3,779,716 WU and the rest is 213,109 bytes of WD with weight 213,109. This makes the total weight of the block 3,779,716 + 213,109 = 3,992,825 WU.

We can now calculate VS:

VS = nWD vBytes + WD/4 vBytes = 944,929 + 213,109 / 4 = 998,206.25 vBytes 

Virtual size (VS) thus cannot be greater than 1,000,000 vBytes, so this is what is meant if someone says that the new block size is still limited by 1 MB - they actually mean 1 million of vBytes.

added 893 characters in body
Source Link
Wapac
  • 1.1k
  • 7
  • 16

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

Now what does it mean? So the size is what you probably understand well – when you have a file on disk, its size is measured in bytes and this is exactly what the size means here. It is the number of bytes you would need to store such a block in memory or on disk. This is the sum of non-witness data (nWD) and witness data (WD). Let's call this the absolute size for clarity (AS).

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

Weight of the block (BW) is calculated in weight units and is calculated as (absolute size of non-witness data) * 4 + (absolute size of witness data). This actually equals what you have mentioned in your post: (tx size with witness data stripped) * 3 + (tx size) because the transaction itself contains both witness and non-witness data.

So, now we know that:

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

What are the limits in the protocol? Currently there is no block size limit any more. There is just one limit for block weight. This limit is set to 4,000,000 WU. It follows that in case of a block without Segwit txs, each byte's weight is 4 WU, therefore, such a block without Segwit txs is limited by absolute size of 1 MB.

Blocks that contain Segwit txs can be bigger than that and there are some theoretical calculations that say you can go to something like 3.7 MB of absolute size of a block. But this theoretical limit is just that – theoretical. In practice, even if the block was full of Segwit txs, its absolute size would not reach this limit.

Currently, most blocks contain both txs - Segwit and legacy, so we see the block sizes of full blocks usually in the range between 1 - 2.2 MB. The block is full if it's weight is very close to the protocol limit of 4,000,000 WU.

This implies that it is not correct to think that a block of size 1.1 MB is composed of 1,000,000 bytes of nWD and the rest is WD. That wouldn't work because the weight of 1,000,000 nWD bytes would already be 4,000,000 WU and therefore if we added the weight of WD to it, we would be over the limit. That is not possible.

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

Now what does it mean? So the size is what you probably understand well – when you have a file on disk, its size is measured in bytes and this is exactly what the size means here. It is the number of bytes you would need to store such a block in memory or on disk. This is the sum of non-witness data (nWD) and witness data (WD). Let's call this the absolute size for clarity (AS).

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

Weight of the block (BW) is calculated in weight units and is calculated as (absolute size of non-witness data) * 4 + (absolute size of witness data). This actually equals what you have mentioned in your post: (tx size with witness data stripped) * 3 + (tx size) because the transaction itself contains both witness and non-witness data.

So, now we know that:

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

What are the limits in the protocol? Currently there is no block size limit any more. There is just one limit for block weight. This limit is set to 4,000,000 WU. It follows that in case of a block without Segwit txs, each byte's weight is 4 WU, therefore, such a block without Segwit txs is limited by absolute size of 1 MB.

Blocks that contain Segwit txs can be bigger than that and there are some theoretical calculations that say you can go to something like 3.7 MB of absolute size of a block. But this theoretical limit is just that – theoretical. In practice, even if the block was full of Segwit txs, its absolute size would not reach this limit.

Currently, most blocks contain both txs - Segwit and legacy, so we see the block sizes of full blocks usually in the range between 1 - 2.2 MB. The block is full if it's weight is very close to the protocol limit of 4,000,000 WU.

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

Now what does it mean? So the size is what you probably understand well – when you have a file on disk, its size is measured in bytes and this is exactly what the size means here. It is the number of bytes you would need to store such a block in memory or on disk. This is the sum of non-witness data (nWD) and witness data (WD). Let's call this the absolute size for clarity (AS).

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

Weight of the block (BW) is calculated in weight units and is calculated as (absolute size of non-witness data) * 4 + (absolute size of witness data). This actually equals what you have mentioned in your post: (tx size with witness data stripped) * 3 + (tx size) because the transaction itself contains both witness and non-witness data.

So, now we know that:

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

What are the limits in the protocol? Currently there is no block size limit any more. There is just one limit for block weight. This limit is set to 4,000,000 WU. It follows that in case of a block without Segwit txs, each byte's weight is 4 WU, therefore, such a block without Segwit txs is limited by absolute size of 1 MB.

Blocks that contain Segwit txs can be bigger than that and there are some theoretical calculations that say you can go to something like 3.7 MB of absolute size of a block. But this theoretical limit is just that – theoretical. In practice, even if the block was full of Segwit txs, its absolute size would not reach this limit.

Currently, most blocks contain both txs - Segwit and legacy, so we see the block sizes of full blocks usually in the range between 1 - 2.2 MB. The block is full if it's weight is very close to the protocol limit of 4,000,000 WU.

This implies that it is not correct to think that a block of size 1.1 MB is composed of 1,000,000 bytes of nWD and the rest is WD. That wouldn't work because the weight of 1,000,000 nWD bytes would already be 4,000,000 WU and therefore if we added the weight of WD to it, we would be over the limit. That is not possible.

added 893 characters in body
Source Link
Wapac
  • 1.1k
  • 7
  • 16

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

Now what does it mean? So the size is what you probably understand well – when you have a file on disk, its size is measured in bytes and this is exactly what the size means here. It is the number of bytes you would need to store such a block in memory or on disk. This is the sum of non-witness data (nWD) and witness data (WD). Let's call this the absolute size for clarity (AS).

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

Weight of the block (BW) is calculated in weight units and is calculated as (absolute size of non-witness data) * 4 + (absolute size of witness data). This actually equals what you have mentioned in your post: (tx size with witness data stripped) * 3 + (tx size) because the transaction itself contains both witness and non-witness data.

So, now we know that:

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

What are the limits in the protocol? Currently there is no block size limit any more. There is just one limit for block weight. This limit is set to 4,000,000 WU. It follows that in case of a block without Segwit txs, each byte's weight is 4 WU, therefore, such a block without Segwit txs is limited by absolute size of 1 MB.

Blocks that contain Segwit txs can be bigger than that and there are some theoretical calculations that say you can go to something like 3.7 MB of absolute size of a block. But this theoretical limit is just that – theoretical. In practice, even if the block was full of Segwit txs, its absolute size would not reach this limit.

Currently, most blocks contain both txs - Segwit and legacy, so we see the block sizes of full blocks usually in the range between 1 - 2.2 MB. The block is full if it's weight is very close to the protocol limit of 4,000,000 WU.

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

Now what does it mean? So the size is what you probably understand well – when you have a file on disk, its size is measured in bytes and this is exactly what the size means here. It is the number of bytes you would need to store such a block in memory or on disk. This is the sum of non-witness data (nWD) and witness data (WD). Let's call this the absolute size for clarity (AS).

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

Weight of the block (BW) is calculated in weight units and is calculated as (absolute size of non-witness data) * 4 + (absolute size of witness data). This actually equals what you have mentioned in your post: (tx size with witness data stripped) * 3 + (tx size) because the transaction itself contains both witness and non-witness data.

So, now we know that:

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

Have a look: https://blockstream.info/block/0000000000000000000cbbceb342e07071f9621607e044ec909aa86fcdf88e8a?expand

Size = 1158.038 KB Virtual size = 999 vKB Weight units = 3992.493 KWU 

Now what does it mean? So the size is what you probably understand well – when you have a file on disk, its size is measured in bytes and this is exactly what the size means here. It is the number of bytes you would need to store such a block in memory or on disk. This is the sum of non-witness data (nWD) and witness data (WD). Let's call this the absolute size for clarity (AS).

What is virtual size (VS) then? This is a new concept, which measures the block in new units, called vBytes. It is calculated as (absolute size of non-witness data) + (absolute size of witness data)/4.

Weight of the block (BW) is calculated in weight units and is calculated as (absolute size of non-witness data) * 4 + (absolute size of witness data). This actually equals what you have mentioned in your post: (tx size with witness data stripped) * 3 + (tx size) because the transaction itself contains both witness and non-witness data.

So, now we know that:

AS = 1158 KB = nWD bytes + WD bytes VS = 999 vKB = nWD vBytes + WD/4 vBytes BW = 3992.493 KWU = nWD * 4 weight units + WD weight units 

What are the limits in the protocol? Currently there is no block size limit any more. There is just one limit for block weight. This limit is set to 4,000,000 WU. It follows that in case of a block without Segwit txs, each byte's weight is 4 WU, therefore, such a block without Segwit txs is limited by absolute size of 1 MB.

Blocks that contain Segwit txs can be bigger than that and there are some theoretical calculations that say you can go to something like 3.7 MB of absolute size of a block. But this theoretical limit is just that – theoretical. In practice, even if the block was full of Segwit txs, its absolute size would not reach this limit.

Currently, most blocks contain both txs - Segwit and legacy, so we see the block sizes of full blocks usually in the range between 1 - 2.2 MB. The block is full if it's weight is very close to the protocol limit of 4,000,000 WU.

Source Link
Wapac
  • 1.1k
  • 7
  • 16
Loading