Will the CPoC consensus mechanism be the YYDS of the distributed search QTC?

1. CPoC consensus mechanism 

1. Nouns and concepts

Shabal/Sha256: Shabal/Sha256 is a cryptographic hash function used in Qitchain Network. Shabal is a rather heavy and slow cryptographic hash function, related to many other functions such as SHA256. Therefore, it can become the encryption algorithm of Qitchain Network. This is because we store the pre-calculated hash value, and it is still fast enough for smaller real-time verification.

Deadline: When starting to build a node and process the Plot file, a value called deadline will eventually be generated. These values ​​represent the number of seconds that must elapse since the last block was forged before the block is allowed to forge. If no one else forges a block during this time, you can forge a block and get a block reward.

Block reward: If the storage service provider is lucky to mine a block, he will get QTC as a reward. This is called a block reward. After every 568288 blocks are generated, the block reward is reduced by 50%.

Base Target: Base Target is calculated based on the latest 288 blocks. This value adjusts the difficulty of storage. The lower the benchmark target, the harder it is for storage service providers to find a deadline with a small value. Its adjustment purpose is to try to make the average block interval time of 3 minutes.

Network Difficulty: NetDiff for short, is a positive value that can be regarded as an evaluation of the storage space of the Qitchain Network. The unit is Byte. This value varies with the block and is based on the Base Target.

Block height: Each block has a separate digital number, and each newly generated block will add +1 to the previous block number. This number is called the block height and is used to identify a unique block.

Generate signature: The generated signature is calculated based on the merkle root of the previous block and the block height. The storage service provider uses this value to generate a new block. The generated signature has a length of 32 bytes.

the PoC Profile

The consensus algorithm of the Qitchain Network has been upgraded on the basis of the traditional PoC (Proof of Capacity) and is called CPoC (Conditioned-Proof of Capacity), which is the conditional proof of capacity.

The so-called conditionalization means that storage service providers need to pledge a certain amount of QTC for the declared capacity to obtain complete block rewards. The CPoC consensus will allow storage service providers, storage service pools, and foundations and other participants to have a positive business game. The entire system will always have a more dominant temporary commercial vested interest (this vested interest will continue to change with time and variable conditions such as price and block difficulty) to invisibly promote the entire ecology.

The CPoC consensus mechanism has the following characteristics:

1) Economic model attack prevention: When storage service providers under the PoW consensus mechanism are forced to sell tokens due to costs, it will cause the entire ecosystem to shrink. The CPoC participation economic model makes storage service providers a community of ecological interests and uses meta-assets. The new means of production replace the original electricity consumption resources, making the ecology continue to expand virtuously.

2) Low maintenance cost: The blockchain system based on PoW consensus needs to consume a large amount of hardware resources and power resources to maintain its security. As a result, storage service providers cannot establish common interests and mutual recognition, and the consumed resources cannot be deposited in it. In the value system, this part of the value is being withdrawn from the PoW system all the time. Without value-driven, it is difficult to update key technologies, thus failing to obtain long-term and effective development and iteration, and it is easy to cause bifurcation in the follow-up.

3) Hardware monopoly: The PoW consensus mechanism will inevitably lead to an arms race in hardware. In order to obtain higher computing power, storage service providers will inevitably develop higher-performance dedicated hardware, and ordinary people cannot participate in the establishment of nodes. The CPoC consensus mechanism is mainly based on hard disks. The hard disk system has slow iteration speed, low threshold, and stable shipments. There is no need to worry about not buying hard disks. Everyone can participate. In the traditional commercial supply chain, suppliers generally do not become direct competitors of users. However, in the PoW system, hardware manufacturers themselves are direct competitors of storage service providers. At the same time, suppliers as storage service providers can directly use storage service providers. End as an arbitrage tool.

4) Power resource monopoly: The power monopoly makes it difficult to expand the PoW endogenous ecology. Storage service providers are far more concerned about cost than their enthusiasm for ecological construction. For the CPoC system, hard disk power consumption is low, and storage service providers will benefit from it. More clearly, the linear hedging rate of civilian computer hardware ensures that storage service providers can obtain value with relatively safe and cost-preserving conditions.

3. CPoC model

For storage resources, in the field of distributed storage, there is a relationship between verification and verification between file owners and file requesters. The core concept behind PoC is that in terms of storage resources, “the prover is inefficient, the verifier is efficient”, so that the verifier can spend very little storage resources, and in less computing time, the verifier has a certain amount of storage resources. The purpose of the storage space.

The most critical issue in the PoC consensus is how the prover (Bob) proves to the verifier (Alice) that he has a file F of a certain file size that always exists in Bob’s disk.

One of the simplest and most intuitive ways is that Alice sends F to Bob in advance, and then Bob returns the same file F when it needs proof. After receiving the file, Alice verifies whether it is consistent with the file previously sent to Bob.

NH19OIt7lokbOEyXIjlUSGGm1XuoisGkifVTouqf.png

 

NH19OIt7lokbOEyXIjlUSGGm1XuoisGkifVTouqf.png

But doing so obviously violates the characteristics of “verify efficient storage resources”.

In the scope of PoC, the purpose of document F is only to prove that the prover does use a certain amount of storage space tools, that is, we can make any form of requirements on the content of document F. In the designed PoC system, the The content is a DAG (Directed Acyclic Graph) structure, with V representing all nodes in the graph, and defining W(V), which is required to meet a characteristic:

  • rikRsc1Gz1RR1fteX4ElWpHqzedVfG4oFzHhzDu3.png

Where V’is the direct predecessor node of V in the graph.

gwwrZd4E9HhVXXQdWEHqLlFSpEoZn1M0JwdNnECz.png

 The prover needs to store the W value of each node for the verifier to randomly select and check during the verification phase. The interaction process between the prover and the verifier is as follows:

1) Initial stage:

  • The verifier negotiates the complex directed acyclic graph G with the prover, and the prover calculates all W(V) and stores the calculation results. The required calculation time is proportional to the storage space and the number of nodes in the graph;
  • The prover composes all W(V) values ​​into a Merkle tree and sends the value of the root node Φ to the verifier;

2) Verification phase:

  • The verifier randomly selects node V, and requires the prover to give the value of its W(V), and at the same time reveal its path in the Merkle tree;
  •  The prover extracts the specific W(V) in its storage and at the same time reveals its path in the Merkle tree;
  • The verifier verifies the legitimacy of its W(V) and at the same time verifies whether it exists in the Merkle tree rooted at Φ.

In the initial stage, an honest prover needs to be required to store the hash value of each node calculated according to the graph structure. Since in practical applications, the number of nodes and connection relationships in the graph are much more complicated than the above figure, the most likely way for the prover to cheat is to store the results of the Hash operation on the disk instead of using a large amount of storage. In the verification phase, computing resources are reused for hashing.

Such cheating with “time for space” is obviously not feasible, because in the limited verification time, it is uneconomical and unrealistic to invest huge computing resources to recalculate the hash value of each node. .

Two specific types of DAGs, Random Bipartite Graphs and Superconcentrator Graphs, are selected. The mathematical characteristics of these two types of graphs ensure the high complexity of the connection relationship between nodes.

By establishing the Pebble Game model, Stefan Dziembowski’s paper can prove that if a dishonest prover does not store the same number of hash values ​​as the graph node, it is impossible to correctly pass the verification of the verifier within a constant finite time.

lw6IQFzSgekW1CqG9bgQgEBINhqZ9EH21d18vKDu.png

In the second step of the initial phase and the second and third steps of the verification phase, the nature of the Merkle tree can be used to simplify the verification complexity of the verifier, so as to achieve the purpose of “verification efficient” for the verifier.

E5kkFbs4VqMx1QEweHg3cI7W3mbN2I31HbOtnqDg.png

The prover uses the W value of each node as the leaf node of the Merkle tree, calculates the root of the Merkle tree, as one of the parameters, and sends it to the verifier in the initial stage. In the verification stage, the verifier only needs to verify the value of a certain node. Whether the value of W exists in the Merkle tree sent in the initial stage of the first step.

4. Conditional model based on PoS

Conditional model based on PoS

On the basis of the PoC consensus, we designed a conditional proof based on the pledge model. This conditional model is jointly formed by two parties, namely the block storage service provider and the top 10 users of the pledge amount.

we use

ngVOiawaVhacI3TWxJ6m2fJwIl73z6H7FPkd2Wom.png

Indicates the block reward finally obtained by both the block storage service provider and the top 10 users of the pledge amount after mining a block, where

XaEAzNzaBcgZ5eno5LcdoOaP0wW9PnQTMw8t3izf.png

Indicates the final reward of the block storage service provider,

5nCmcBzyQas0FVqpLe96UCMQYYA4G7y7a4oWEGMO.png

Represents the final reward jointly obtained by the top 10 users of the pledge amount, ρ represents all the block rewards produced after a block is produced,

h1YwJCwZNo7h2nhX1sLLZZbHRgVxcb6UjoMTdEF2.png

It represents the amount of staking required by the block storage service provider to meet the requirements of the conditional model, and staking represents the actual staking amount of the storage service provider.

:

3s7UrPf3qNaiuIfaHk4OvmoAfJNKd9S8Bm582qyL.png

1) Difficulty competition and block generation

The storage service provider obtains storage information from the wallet, which includes the new generated signature, base target, and the height of the next block. Before the wallet sends this information, create a signature by creating the last generated signature and plot id, and run this method through Shabal256 to obtain a new hash. The storage service provider will use the new 32-byte generation signature and 8-byte block height, and put them together as the seeds of Shabal256 to calculate the hash.

SiNejThuWJxYM1wzDP6YOjCvBpBBAaGPhiQmAO7B.png

The miner performs small-scale mathematical calculations on the hash, modulo 4096 through the hash, and finds out the scoop number.

2SnE1kL0p8fT5O1fwvMt2kBX5WaNMTXXfFKgXJIf.png

Then read the plot file, obtain and process scoop from all the nonces to calculate the target hash, define target as the target hash, then the target can be expressed as:

VAlfrXWzGfVf2RtjctHyMVX1kqzWPP1OCsJCtwo0.png

The target is divided by the base target, the first 8 bytes obtained are the value of deadline, then the deadline can be expressed as:

fKwd2zoEDVIOib4BdzhNZ34CkXA1q1hIDNQPWERZ.png

XgtBM2xKQtHmRqPLpFVtT5vo76mdekvZ8ix6WQUg.png

After the wallet receives the information submitted by the storage service provider, it creates a corresponding nonce to find and verify the deadline. Then the wallet will check the time remaining (unit: second) corresponding to the deadline until the time corresponding to the deadline runs out. If a valid block from another wallet is received on the network before the deadline is exhausted, the wallet will discard the submitted hash information. If the storage service provider submits new information, the wallet will create a nonce and check whether the deadline value is lower than the previous deadline. If the new deadline is smaller, the wallet will use that deadline.

When the deadline is valid, the wallet starts to construct a new block. First, the wallet gets all unconfirmed transactions received from users or the network. The wallet will try to include as many transactions as possible until it reaches the upper limit of 2M size, or until all transactions are processed. The wallet checks the legality of all transactions received, such as whether it has a valid signature, correct timestamp, legal input and output, etc. The wallet will also count the amount and cost of all added transactions.

Summary: From the perspective of ecological governance

Under many staking economic models, QTC’s CPOC consensus mechanism is the first to be able to manage the token trends of large storage service providers technically, stimulate buying, reduce selling pressure, increase the deflation mechanism of the economic model, and better To achieve the benign autonomy of the QTC community ecology, this is the innovation of the entire industry.

2. The current KPIs of QTC:

5fp8U3OxwyjGz1tmK1V1qThNorMQgAG3bOCZ5Vel.png

1) The total computing power of the entire network is stable at: 207P

2) The current hashrate of the mining pool has increased to: 90P

3) Current OTC price: 1Q=$61 (¥384.3), an increase of 2.22%

3. Interpretation of QTC economic model

When discussing economic models, you have to understand the consensus mechanism in the blockchain field. The current consensus mechanisms in the blockchain field are listed as follows:

POW (Proof of Work Mechanism), POS (Proof of Equity), POC (Proof of Capacity), POA (Proof of Authority), CPOC (Conditional of Proof of Capacity)

1. POW (Proof of Work Mechanism)

POW is the first blockchain consensus algorithm. Since 2009, it has appeared with the emergence of Bitcoin . Simply put, the POW consensus algorithm is to confirm the workload of network participants and give certain rewards.

 In the POW consensus algorithm, the initiator is required to perform a certain amount of calculation, which means that a certain amount of calculation time needs to be consumed. In the operation of this algorithm, when network participants add a transaction to the blockchain, they must first solve a certain complex calculation problem.

 This method can ensure that network participants spend a certain amount of time and money to complete the work, which shows that they will not damage the blockchain system, because damage to the system will lose their own interests.

For example, Bitcoin and Ethereum both use POW consensus algorithms, and are currently the two largest blockchain networks with the strongest consensus. The advantage of POW is the most secure consensus algorithm, which can effectively prevent 51 attacks. Since its launch in 2009, it has been widely recognized. The disadvantage is that it consumes more energy and the throughput is slower. 

F4324wZa5wrfgugj9uwg7DaigU3q4u5zPH9n6Feu.png

2. POS (Proof of Rights and Interests Mechanism)

POS is also known as proof of equity, similar to bank deposits. Under this consensus algorithm, corresponding rewards will be distributed according to the digital assets held by network participants and the holding time, which is similar to the interest paid by banks to deposits.

The emergence of POS is actually to solve the problem of high energy consumption in POW, so it does not use computing functions. Network participants do not need to consume huge energy, but must have digital assets that represent the network.

The more the digital assets owned by the network participants and the longer they hold them, it is proved that the more the participants contribute to the network, the more trustworthy they are. The probability that the participants will get the next block reward in the network Bigger.

For example, Ethereum is shifting from POW to POS consensus algorithm. In the POS consensus algorithm of the Ethereum network, users need to pledge 32 ETH (Ethereum’s digital assets) to become a validator. Verifiers are randomly selected to create blocks and are responsible for checking and confirming blocks that they have not created. The ETH pledged by users can also receive a certain pledge reward.

The advantages of POS are high attack cost, energy saving, and large scalability, and as long as there are digital assets of the network, it can participate in the network, so it is not susceptible to the impact of economies of scale. The disadvantage is that once a complete attack is encountered, the entire network will lose value.

plXlQh9imJ8OsfWjBk6MBKbDh9nrrv6CmUFijWGI.png

 3. POA (Proof of Authority Mechanism)

 POA is not an independent consensus algorithm, but a consensus algorithm that combines POW and POS. In the POA consensus algorithm, each active node first needs to perform hash calculations according to the POW mechanism. After the node has calculated the correct hash value and successfully verified, it will use the block as the data source and derive N A random equity owner. These selected equity owners are the first approved accounts and are called validator nodes.

 The verifier node must first authenticate its own identity, where it needs to use a widely recognized identity that exists in a public notarized database, which is a mandatory process.

At the same time, the POA algorithm requires all validator nodes to be online. If any validator node is not online, the generated new block cannot be verified, and the new block is discarded.

The POA consensus algorithm will periodically count the number of discarded blocks, and adjust the number of validator nodes based on this number. If the number of discarded blocks is large, the number of validator nodes will be reduced, otherwise, the number of validators will be increased. node.

 For example, VeChain in the public chain track is designated by the project foundation as an “authoritative master node” to maintain the operation of the VeChain network. Each node operator must hold at least 25,000,000 VET at any given time.

 At present, the corresponding authority is composed of 101 VeChain “source of thunder” super nodes. The authoritative master node is the only node authorized to package blocks on the VeChain Thor blockchain. They will receive 30% of the transaction fee for each block. % Reward.

The advantage of the POA consensus algorithm is that it can prevent attackers who have strong computing power but only hold a small amount of equity. The POS part makes the possibility of these attackers getting blocks is very small, so effective attacks cannot be carried out. The validator node relies on assets to make profits, which will make the validator hold the asset for a long time, which is conducive to the preservation of the digital asset and the reduction of volatility. The disadvantage of POA is that it is slightly centralized and usually does not guarantee censorship resistance.

cafXeCViNGOlIN2G7Szwr7dxsvdWldpBRBVCI1An.png

4. POC (capacity proof mechanism)

POC is also known as proof of space. The algorithm is similar to POW, except that it uses space instead of CPU for calculations.

In the POC consensus algorithm, network participants use the hard disk space of the computer to store the hash value calculated in advance. The larger the capacity of the hard disk, the more hash values ​​stored in the hard disk, and the easier it is to match the required hash values ​​in the block network, thereby obtaining more block rewards.

The POC consensus algorithm requires that the hash value be calculated in advance and stored in the hard disk, so network participants do not need to perform real-time calculations, only need to scan the disk in the hard disk to find the hash value that matches the block. It can generate new blocks, that is to say, compared with POW, the POC consensus algorithm can save a lot of calculation time and energy.

For example, Chia of the distributed storage track, when Chia first came out, its “green BTC “, low threshold and other features attracted a large number of people in the blockchain field to enter.

Obtain block rewards by continuously scanning the hash value that matches the block in the hard disk. At present, the capacity of Chia’s entire network has reached 35.16 EiB, which is currently the largest project in the entire network.

The advantages of the POC consensus algorithm are energy saving, environmental protection, and low participation threshold. As long as there is a hard disk, it can participate in the network.

The disadvantage is that the widespread adoption of POC may trigger a race to produce higher-capacity hard drives, increasing the threshold for personal participation and the risk of being attacked. At the same time, there is no way to carry out benign and positive community governance. The long-term and stable storage income of storage service providers cannot be guaranteed!

 5. CPOC (conditional capacity certification mechanism)

 CPOC is a consensus algorithm upgraded on the POC consensus algorithm, adding a POS consensus mechanism. In the CPOC consensus algorithm, network participants also use hard disk space to store hash values, thereby participating in the competition for block rewards. At the same time, network participants can also pledge their digital assets to obtain more block rewards.

 In the CPOC consensus algorithm, a true low-threshold participation is achieved.

First, CPOC uses hard disks to participate in the network. The cost of nodes in the network is low, and idle hard disks can also be used to participate. Second, holding digital assets in the network can also participate and get rewards. In other words, network participants who pledge more digital assets will receive more block rewards.

 For example, based on Bitcoin’s underlying code, further adding smart contracts, developing applications and developing its ecosystem ” BTC 3.0″-distributed search engine QitChain, the ultimate goal is to become an effective information aggregator, and its internal economic mechanism adopts The consensus algorithm of CPOC. Individuals or institutions with hard disks or digital assets can participate in the network. Network participants can use the hash value filled in the hard disk to obtain certain block rewards, and can also increase the area by staking their digital assets. The number of block rewards, the top ten nodes with the most pledges can get more rewards.

cdmMFi1pS6Wexua7UO1ctZIe8oWWvWB80aHoCs1H.png

The advantages of the CPOC consensus algorithm are low energy consumption and environmental protection; under the POS mechanism, the digital assets in the network can obtain effective demand and support the internal circulation of the network.

The disadvantage is that the CPOC consensus algorithm is an innovative consensus mechanism, which requires continuous development of its application to obtain a stronger consensus (Qitchain will also usher in an ecological explosion due to technical updates and expansions in the next 2 years. This will be explained in depth in this research article) .

 In addition to the five consensus mechanisms mentioned above, there are DPOW (Delayed Workload Proof Mechanism), DPOS (Authorized Stake Proof Mechanism), PBFT (Practical Byzantine Fault Tolerant Mechanism), DBFT (Authorized Byzantine Fault Tolerant Algorithm), POB ( Consensus algorithms such as burn proof mechanism) are basically to form a stronger consensus in the blockchain network that is recognized by more people.

Therefore, in the blockchain field, success or failure lies in consensus. Consensus determines the superstructure. It will be yyds…

 Fourth, QITChain’s data analysis:

Of9JiJdBzlHaECs2HSwmcRJWN1C9CGLSdK0ExQze.png(Picture source: collation of the white paper)

The daily output of QTC’s entire network is: 75Q/3 minutes X20X24=36000Q

QTC storage service provider’s daily income: 36,000 X80%=28800Q

QTC output per year: 36000X365 days = 13.14 million

QTC project parties release each year: 21 million/5 years = 4.2 million

The total number of spot Q in circulation each year by QTC = 1314 + 420 = 17.34 million

According to the QTC economic model, the maximum storage capacity supported by QTC’s annual spot quantity is: 17.34 million/5Q (the amount required for 540 days of pledge per T) = 3.468 million T=3386p (1P=1024T);

From the perspective of consensus alone , if the annual storage capacity of QitChain exceeds 3386P, the secondary market will appear embarrassingly difficult to find.

In the process of achieving the 3386p goal of the first phase, QITChain will continue to update and upgrade the bottom layer, and it will usher in an ecological explosion at the height of the 700,000th block…

Posted by:CoinYuppie,Reprinted with attribution to:https://coinyuppie.com/will-the-cpoc-consensus-mechanism-be-the-yyds-of-the-distributed-search-qtc/
Coinyuppie is an open information publishing platform, all information provided is not related to the views and positions of coinyuppie, and does not constitute any investment and financial advice. Users are expected to carefully screen and prevent risks.

Like (0)
Donate Buy me a coffee Buy me a coffee
Previous 2021-11-15 21:34
Next 2021-11-15 21:38

Related articles