BTQ Docs
Concepts

Consensus & Proof of Work

How BTQ achieves distributed agreement

Consensus & Proof of Work

BTQ uses Proof of Work (PoW) consensus, the same mechanism that secures Bitcoin. This page explains how thousands of independent computers agree on the state of the blockchain.

The Consensus Problem

In a decentralized network:

  • No central authority decides what's true
  • Nodes may receive conflicting information
  • Some nodes may be malicious
  • Network delays cause different views

How do we agree on a single history?

Proof of Work

Proof of Work solves consensus through computational effort:

  1. Mining: Nodes compete to solve a mathematical puzzle
  2. Difficulty: The puzzle is hard to solve, easy to verify
  3. Reward: The winner gets to create the next block (and earn coins)
  4. Chain Selection: The longest valid chain is the truth

The Mining Process

┌─────────────────────────────────────────────────────┐
│                    Mining Loop                       │
├─────────────────────────────────────────────────────┤
│                                                      │
│  1. Collect pending transactions from mempool        │
│                     │                                │
│                     ▼                                │
│  2. Build candidate block with:                      │
│     - Previous block hash                            │
│     - Merkle root of transactions                    │
│     - Timestamp                                      │
│     - Difficulty target                              │
│     - Nonce = 0                                      │
│                     │                                │
│                     ▼                                │
│  3. Hash the block header                            │
│     hash = SHA256(SHA256(header))                    │
│                     │                                │
│                     ▼                                │
│  4. Is hash < target?                                │
│     ├── YES: Block found! Broadcast to network       │
│     └── NO: Increment nonce, go to step 3            │
│                                                      │
└─────────────────────────────────────────────────────┘

The Hash Puzzle

Miners must find a block header that, when hashed, produces a value below the target:

Target:    0x00000000FFFF0000000000000000000000000000000000000000000000000000
Valid:     0x000000003a2b1c... (below target - VALID)
Invalid:   0x0000000a7f8e2d... (above target - INVALID)

The more leading zeros required, the harder the puzzle.

Why It Works

  • Expensive to produce: Finding a valid hash requires trillions of attempts
  • Easy to verify: Checking a hash takes microseconds
  • Unpredictable: You cannot know which nonce will work
  • Probabilistic: More hash power = more likely to find blocks

Difficulty Adjustment

BTQ adjusts difficulty every 20,160 blocks (~2 weeks):

New Difficulty = Old Difficulty x (2 weeks / Actual Time)

This maintains approximately 1-minute block times regardless of total network hash power.

If blocks are found too fast: Difficulty increases If blocks are found too slowly: Difficulty decreases

Chain Selection

When multiple valid chains exist (forks), nodes follow the longest chain rule:

        Block 100
           │
     ┌─────┴─────┐
     ▼           ▼
  Block 101a   Block 101b
     │           │
     ▼           ▼
  Block 102a   Block 102b
     │           │
     ▼           X
  Block 103a
     │
     ▼
(This chain wins)

The chain with the most cumulative work is considered valid. Shorter chains are abandoned (orphaned).

The Mining Reward

Miners receive:

  1. Block Subsidy: New coins created with each block

    • Started at 5 BTQ
    • Halves every 2,100,000 blocks (~4 years)
    • Eventually reaches 0 (max 21 million BTQ)
  2. Transaction Fees: Paid by users for inclusion

    • Becomes more important as subsidy decreases
Total Block Reward = Block Subsidy + Transaction Fees

Security Model

51% Attack

An attacker with >50% of hash power could:

  • Double-spend their own transactions
  • Prevent specific transactions from confirming
  • Block other miners from finding blocks

They cannot:

  • Steal coins from others (need private keys)
  • Create coins out of thin air (invalid blocks rejected)
  • Change old transactions (gets harder over time)

The 51% attack becomes exponentially harder for older transactions. 6 confirmations is considered very secure for most purposes.

Hash Power Economics

Mining is profitable when:

Block Reward Value > Electricity + Hardware Costs

This creates a natural equilibrium:

  • High coin price = More miners = More security
  • Low coin price = Fewer miners = Lower security (but also lower attack cost)

Transaction Confirmation

Mempool

Before inclusion in a block, transactions wait in the mempool:

User creates transaction
         │
         ▼
Broadcast to network
         │
         ▼
Nodes validate and add to mempool
         │
         ▼
Miners select transactions (usually highest fee first)
         │
         ▼
Transaction included in block
         │
         ▼
Block mined and propagated
         │
         ▼
Transaction confirmed

Confirmation Depth

ConfirmationsSecurity LevelUse Case
0UnconfirmedDangerous for any value
1InitialSmall purchases
3StandardMedium transactions
6HighLarge transactions
60+Very HighExchanges, critical transfers

Block Propagation

When a miner finds a block:

  1. Announce: Send block header to peers
  2. Request: Peers request full block
  3. Validate: Each node independently validates
  4. Accept: Valid blocks added to chain
  5. Relay: Nodes relay to their peers

This happens in seconds across the global network.

Forks

Soft Fork

A rule change that is backward-compatible:

  • Old nodes still accept new blocks
  • New nodes may reject some old-style blocks
  • Example: SegWit activation

Hard Fork

A rule change that is NOT backward-compatible:

  • Old nodes reject new blocks
  • Network splits into two chains
  • Example: Bitcoin Cash split from Bitcoin

BTQ is a hard fork of Bitcoin with new signature rules.

Comparison with Other Consensus

MechanismUsed ByEnergySecurityDecentralization
Proof of WorkBTQ, BitcoinHighVery HighHigh
Proof of StakeEthereum 2.0LowHighMedium
Delegated PoSEOSLowMediumLow
Proof of AuthorityPrivate chainsVery LowLowVery Low

BTQ uses Proof of Work because it provides the strongest security guarantees and has been battle-tested for over 15 years with Bitcoin.

BTQ-Specific Considerations

Larger Transactions

Dilithium signatures are larger than ECDSA:

  • ~3,800 bytes vs ~250 bytes per transaction
  • Fewer transactions per block
  • Higher fees per transaction (more block space used)

Same Mining Algorithm

BTQ uses SHA-256 for mining:

  • Existing Bitcoin mining hardware works
  • Well-understood security properties
  • Decentralized mining ecosystem

Summary

  1. Miners compete to solve a cryptographic puzzle
  2. Winner creates the next block and earns rewards
  3. Nodes validate independently (no trust required)
  4. Longest chain wins in case of conflict
  5. Difficulty adjusts to maintain 1-minute blocks
  6. Security increases with more hash power and confirmations

This mechanism has secured billions of dollars of value for over a decade.

Learn More

On this page