The blockchain is the book of the village of Bitcoin World. Whoever digs into the mine, whoever has the right to open a new page in this account, and writes down the new page, "X-year X, mine in the village" Get a bitcoin and get a fee for the reward."
Bitcoin is on fire again. Why do you want to say it again? Because Bitcoin has been fired once in 2013. The same as in 2013, the price of Bitcoin has soared, making people staggering. Unlike 2013, this time people are not only concerned about the price of Bitcoin, but also about the technology behind Bitcoin – the blockchain.
Overnight, the blockchain stood behind the stage and reached the spotlight, becoming a hot spot for people to pursue. Logistics, medicine, copyright... It seems that everything can be reborn with the blockchain. So, what is the magical technology?
This article introduces bitcoin and blockchain systems in the most popular language, without involving any advanced mathematics and computer knowledge.
Speaking of the blockchain, you have to say bitcoin. Bitcoin is the best carrier for blockchain technology. So this article uses Bitcoin as an example to introduce the blockchain.
Bitcoin is very bullish, and cattle are in two characteristics: decentralization, electronic money.
Don't underestimate these two points. It is not easy to have these two points at the same time.
First of all, decentralization, usually decentralized currency generally goes back a long time ago. In ancient times, people spontaneously used shells and stones as a prototype currency. At this time, the currency can be regarded as decentralized. Currency - no central bank is required to organize the issuance and confirm the legality of the transaction.
However, the drawbacks of using such currency do not need to be said more. The unstable supply of money depends on the annual shellfish production; the quality of the currency varies, some are small and small, some are flowers and some are literary; the transaction is very cumbersome, the block trade It’s going to be a few shells of cars, so many currencies are shipped and easy to be robbed.
So the currency evolved, the credit currency era came, the currency became the number in the bank account, the above problems were solved, but we must need the bank to control the issuance of money, anti-counterfeiting, to settle the transaction, our property rights are all in the possession In the hands of the bank. Banks like to move some QE to put some water, and the money in our bank cards is depreciating more and more.
At this time, we hope to have a currency that can be used like a shell without the need for banks to intervene, and in line with the current information age needs for currency functions. Thus, the combination of these two characteristics in one bitcoin was born.
The basic principle of BitcoinAs a currency, it usually has to satisfy several characteristics: someone has to issue it, to be able to hold it, and people can exchange it with each other.
hold
Holding Bitcoin is very simple, as long as you have a payment address, you can hold Bitcoin and accept Bitcoin. The number of Bitcoins held is just a number under this address.
Some people may ask, this is not the same as a bank account, it is very similar, but the substance is very different. The banking system is a centralized system. The balance of the account is calculated by the bank. When the bank system error balance becomes 0, you can't get the money from the ATM.
Bitcoin does not use this authoritative central institution, but also needs a stable accounting system, so the solution is that every “miner†has all the transactions recorded in the Bitcoin world on its own hard disk. With all the transaction records, it is easy to calculate how much balance each person has. This transaction record, which is stored on everyone's computer, is the blockchain. Hackers can hack some blockchains saved by some people, but he can't do most of the world's people. As long as most of them still hold the correct blockchain, the whole system can be restored to normal through error correction.
Just like playing mahjong, we sometimes use bookkeeping to record the receivables and payables per round. The Bitcoin world also trades through bookkeeping. Every transaction is made public, and everyone records the transaction in their own. On the small ledger, how much money each family has, everyone can find out on their own small books. It is only when the bookkeeping is changed from 4 people to the villagers of the entire Bitcoin world, which requires a slightly more complicated system.
issued
Let's take a look at the release. Let's first look at how the banknotes are issued. It is very simple. The central bank started the printing press and there was a lot of "Mao Grandpa" in a flash. As a decentralized electronic currency, bitcoin does not have a central bank, so how to issue it?
Bitcoin stipulates that people can answer a difficult question. Whoever answers first, who can issue a bitcoin, is what we call "mining."
What is this difficult problem? It is a problem with hashing. The hash is a function F that performs some operations on the input X to get the hash value Y. That is, we have high school Y = F (X). The problem that Bitcoin lets you answer is to tell you the hash values ​​Y and F and ask for X.
At this time you will say, this is not an inverse function. Sorry, the hash function is a special function. You can't find a suitable inverse function. To find X, the only way is to try one by one. Put each number into F and see if the result is Y. If it happens to be right, then this question will be answered.
Therefore, the so-called currency issuance and mining are actually a group of people using the best computer to hit the big luck. When a miner is X, that is, after digging into the mine, he has the right to create a new trading block at the end of the original blockchain. On this newly created trading block, the miner It can be accompanied by a Bitcoin world as a payer, and the payee is a person who trades, so that he creates and distributes a bitcoin through this transaction.
A blockchain is made up of a series of trading blocks. Let's see what is included in the trading block.
A trading block will show who is its parent block, contains the transaction records on this block, and the hash value of this block.
In this way, as the miners continue to mine to create new trading blocks, the blocks one after another become a string, becoming a veritable blockchain! In the bitcoin world, for some reason, the blockchain will be forked (why will be forked below), so the Bitcoin world stipulates that the only legal blockchain is the longest blockchain.
The blockchain is the book of the village of Bitcoin World. Whoever digs into the mine, whoever has the right to open a new page in this account, and writes down the new page, "X-year X, mine in the village" Get a bitcoin and get a fee for the reward." This books is very special, not managed by the village party secretary, but all the villagers a staff, who later dug mine, you can flip bookkeeping yourself and let the village people do in the same manner, in order to ensure full The accounts of the village owners are the same. When there is an inconsistency in the account book of the whole village, it is stipulated which person's account book is the longest to listen to.
issued
The key point of Bitcoin is trading. For a decentralized electronic money system, trading is risky. Imagine that your electronic money transaction with another person is similar to a waiver, and that this owe has no third-party notary. If one of them suddenly turns his face, the validity of the debt is difficult to guarantee.
Since it is impossible to use a third-party notary like a bank settlement center (using a centralized system), Bitcoin simply makes people around the world a notary.
All Bitcoin transactions can't be sneaky, and the deal needs to be broadcast to the world via the Internet. If C wants to give B 0.5 bitcoin, it will broadcast to the world "C gave B 0.5 bitcoin!", then all mining miners will add this transaction record to the transaction they are digging. In the block.
Why do they want to add? Because when the miner digs out the mine, in addition to a bitcoin that stipulates the reward, each additional transaction record will add a little more handling fee. Mosquito meat is also meat, and the hard miners don't like it.
In the process of adding transaction records to the block, the miners will first verify that the transaction is illegal, that is, to check the account book in the village. When the currency of C is less than 0.5, the transaction record will be Refuse to join the block.
Adding to the block does not mean that the transaction has been successful. Only when the random number X of the block containing the transaction record is discovered by a miner and a new transaction block link is created in the current block can it be considered as Legal transactions, this transaction record becomes a verified transaction.
B may ask, that is to say, after C sent a broadcast to me, I can't immediately determine if I received the money.
Yes, C broadcast, only C is standing in the village entrance to the village, shouting "I give B five cents!", only when the whole village heard, wrote this matter in a self-book On the page, and the page that recorded the matter was turned over by the miners, the fact that B’s account had an additional five cents was really recognized by the villagers. Due to the large number of miners involved in bitcoin mining, the verification time required for each transaction is usually very short and does not give the transaction a sense of delay.
As a result, the issuance and trading of Bitcoin are linked together end to end. The transaction was carried out in the form of a broadcast, and the miners heard the broadcast and wrote the transaction in the trading block; the miners confirmed the completion of the historical transaction by mining, and created new blocks, extended the blockchain, and issued New bitcoin.
Partition of blockchainThe fork of the blockchain was mentioned before. Why is there a fork in the blockchain? The reason is decentralization.
Without the center, everyone maintains their own books, so they are trapped in the network's delay, communication is not enough, it is inevitable that there will be differences.
To give two examples, one is the problem that is easy to occur when mining: Miner B has a random number, mining success, and extended the blockchain. Note that the blockchain extended by Miner B is only his own. No one else knows about it. Of course, Miner B immediately released the news of successful mining to the world, letting everyone extend the blockchain according to his method.
But at this time, another miner C also had a random number. He had not heard B's broadcast because of the speed delay, or he heard the broadcast but was reluctant to destroy the rules, so he also put his own area. The blockchain has been extended and it has begun to broadcast to the world.
Because of the delay of the network speed, not everyone will first hear the B broadcast. At this time, some people will update the blockchain according to the instructions of B. Some people update the blockchain according to the instruction of C, and because of the speed of the network. Delay, we can't determine whether B or C is the first broadcast, which causes the blockchain to fork.
Just like the two miners B and C in the village lived in the village east and the village west respectively, B and C successfully mined at the same time, turned their own books, and wrote their own declaration on the new page. X Year X The village B (C) mined and got a bitcoin, and began to shout to the village to turn the whole village to page and write this sentence. As they lived at the two ends of the village, the people in the east of the village heard B yelling and then booked according to the words of B. The people in the west of the village first heard C yelling and then booked according to C, resulting in the whole village. There are two versions of the ledger at this time.
The second case is a double transaction, B and C trade, the release of the broadcast announced to pay a bitcoin C, but B also hooked with D, almost simultaneously released a broadcast announced to pay D a bitcoin, even worse Yes, B announced that he was paying the same one.
As in the first case, due to the speed problem, some miners first heard the B and C transactions broadcast, and recorded this transaction record into the current trading block, then heard the B and D transactions, and decided Not legal, refused to add to the trading block. The other part of the miners, on the other hand, only added the B and D transactions to the trading block.
These two situations are not uncommon. Because the Bitcoin world is attended by people all over the world, some areas use 100M optical broadband, and some places use 56K dial-up Internet. The network speed varies widely, and there are many people. The heart is not in the right place, and the heart is evil, so the blockchain fork is happening almost all the time. At this point, the highest principle of the Bitcoin world works: the only legal blockchain is the longest blockchain.
However, as far as the above two forks are concerned, at this time, the two blockchains of the fork are as long as ah? It doesn't matter, these two are legal and not legal. Let's put aside the dispute and continue to dig, to see who is dig fast, who will first revisit the new X, let their blockchain go further, who's blockchain It becomes the longest and becomes the only legal one. After listening to this, how do you feel that this blockchain system is so casual, and some are not reliable? If everyone does not follow the rules and arbitrarily forks, the world will not be confused.
Don't worry, let's find out through analysis that the final blockchain will definitely return to a stable one.
Let us return to the first case of Miners B and Miners C divergence, assuming that B's chain goes further and becomes the longest chain, and this chain becomes the legal chain recognized by Bitcoin. At this point, C has two choices. One is to give up the effort, and throw away his blockchain and use B. Another option is not to be willing to fail, throwing on your own blockchain, hoping that you can continue to tie B and go ahead.
Choosing the former is everyone's happy, and the blockchain of the Bitcoin world has been unified since then, and the latter has actually continued to keep the blockchain in a forked state. So from a rational perspective, what should C do? In fact, C should decisively give up his own chain at this time.
We can analyze that when the chain of B and C is forked, there are four types of miners, two forces in the world of Bitcoin, B and the melon miners who support B, and C and the miners who support C. At this time, the B forces are roughly the same as the C forces, so everyone digs each.
When the B forces first extended the chain of B, the C forces will differentiate at this time. Most of the people who support C will hear the B chain extension and will immediately switch to the B chain. The B chain is longer and it is obviously more promising to continue mining on longer chains. The forces immediately reversed, and C will find that the whole world is against him (cry). So C had to give up.
Of course, suppose that the forces of C first extended the blockchain, then the opposite is true, and miners all over the world will immediately enter the embrace of C. Although it may indeed be the mine that B first digs, at this time B has to choose to give up his own blockchain that has no one to care about. According to this rational assumption, most miners around the world will work on the longest chain, so occasional forks are not a big deal.
Of course, there is still an extreme situation, that is, the computing power of B or C alone exceeds 50% of the world's computing power, and at this time they may overtake with their own power. But in fact, because the whole world is involved, it is difficult for people or organizations to have such a strong calculation power. Secondly, even if C has such a strong calculation power, he can honestly mine the longest chain, and it is not good. It is necessary to harden the world, and to show that hegemony will only make the world not play with him. In the end, bitcoin loses value and C loses more.
The solution to the second type of bifurcation mentioned above is the same as the first case. The principle that “the only legal blockchain is the longest blockchain†is unshakable. The final legal blockchain is only One of the B and C transactions or the B and D transactions will be recorded. The specific reason for the reader can think for themselves.
Having said that, you can see that Bitcoin's clever design of blockchain makes trading and distribution in a very stable state, and what is the core strength to maintain stability? It is the computing power provided by countless miners.
As long as there are enough miners, the calculation power is large enough, and the verification speed is fast enough, the Bitcoin transaction can be quickly verified, and the accidental blockchain fork state can be quickly ended, ensuring stable operation of the entire system. Therefore, mining is not just about electricity, this energy is actually transformed into the energy to maintain the stability of the entire system!
This also tells us why Bitcoin can be worth tens of thousands of dollars, and some newly issued coins are worthless, because Bitcoin is the longest and most widely used electronic currency, and it has the largest number and the widest distribution. Miners and computing power are the most stable electronic money.
However, the number of newly issued currency miners is small, and the computational power of participation is low, which does not play a role in stabilizing the entire system. The low computing power also means that the verification time of each transaction will become longer, thus reducing the availability of money, so The emerging currency is worthless.
Welded Stainless Steel Pipe,Disposable Welded Stainless Steel Pipe For Laboratory,Medical Welded Stainless Steel Pipe,High Precision Welded Stainless Steel Pipe
ShenZhen Haofa Metal Precision Parts Technology Co., Ltd. , https://www.haofametals.com