Professional Documents
Culture Documents
Lecture #2
By
Engr. Aamir Baloch
Consultation Hours: 11:00AM to 2:00 PM
Contact via WhatsApp
Reflection
• Course Details
• Marks Distribution
• Background of Blockchain
• Various Definitions of Blockchain
2
Run Down of Lecture
• Elements of Blockchain
• Types of Blockchain
• Benefits of using Blockchain
• Group Exercise
3
Elements of Blockchain
We have the following elements:
• Hash
• Nodes
• Miners
• Ledger(Block/Blockchain)
• Proof of work
• Network consensus
• Double spending problem
4
Hash
• A hash is a string of numbers and letters.
• Each transaction generates a hash.
• Transactions are entered in an order in which
they occurred. Order is very important.
• The hash depends not only on transaction but
the previous transaction’s hash.
• Even a small change in transaction creates a
completely new hash.
Node
• A blockchain is spread over many computers,
each of which have a copy of blockchain,
these computers are called nodes.
• Nodes check to make sure a transaction has
not been changed by inspecting the hash.
• A blockchain updates itself every 10 minutes.
6
Miners
• Miners, in context of cryptocurrencies like
Bitcoin, are individuals or entities that
participate in the process of validating and
adding new transactions to the blockchain.
• They do this through a process called “mining”
which involves solving complex mathematical
puzzles using computational power.
• Mining is essential for maintaining the security
and decentralization of blockchain newtwork.
7
Ledger
• A ledger is a record-keeping system or database
that is used to track and store financial
transactions.
• It provides a chronological and organized
account of all financial activities within an
organization, individual, or any other entity.
• Ledger often called a “blockchain” because
transactions are grouped, and each block is
linked to the previous one, forming a chain of
blocks.
8
Proof of work (PoW)
• Proof of work is a mechanism which is used in
blockchain networks, specially in
cryptocurrencies like Bitcoin.
• It is an agreement between participants in
network to confirm the transactions.
9
Network consensus
• Network consensus refers to the collective
agreement between participants in a
distributed network , typically a blockchain or
a p2p network , regarding the overall state of
the network and validity of transactions.
• Consensus is a vital aspect of blockchain
network that ensures all participants have a
consistent and accurate view of the data can
trust the information stored on the network.
Continued..
• Consensus is designed to prevent malicious
actors from manipulating the network and
ensure that only valid transactions are added
to the blockchain.
• Consensus is essential for maintaining the
integrity , security , and reliability of
decentralized systems.
11
Double spending problem
• The double spending problem is a critical issue
in digital currencies and electronic payment
systems, especially those without a central
authority.
• It refers to the risk or possibility of spending
the same unit of digital currency more than
once.
12
Solution to double spending problem
• To prevent double spending in digital currencies
, various mechanisms have been developed.
• One common solution is the use of a
decentralized ledger with consensus
mechanisms like Pow.
• These ensure that only one valid transaction is
added to ledger.
• Making it extremely difficult for someone to
spend the same digital currency twice.
13
Types of blockchain
There are following four types of blockchain:
• Public Blockchain
• Private (or managed) Blockchain
• Consortium Blockchain
• Hybrid Blockchain
14
Public Blockchain
• Public Blockchains are permissionless in
nature, allow anyone to join, and are
completely decentralized.
• Anyone who has access to the internet can
sign in on a public Blockchain platform to
become authorized node and be a part of the
blockchain network.
• Examples: Bitcoin.
Private or managed Blockchain
• A private Blockchain is managed by a network
administrator and participants need consent to
join the network which means it is a
permissioned blockchain.
• Private Blockchains are usually used within an
organization or enterprises where only selected
members are participants of a blockchain
network.
• Examples: Multichain and Hyperledger projects.
16
Consortium Blockchain
• A Consortium Blockchain is a semi-
decentralized type where more than one
organization manages a blockchain network.
• This is contrary to what we saw in a private
blockchain, which is manage by only a single
organization.
• Examples: Energy Web Foundation, R3
17
Hybrid Blockchain
• A hybrid Blockchain is a combination of the
private and public Blockchains.
• It uses the features of both types that is one
can have a private permission-based system as
well as a public permission less system.
• Examples: Dragonchain
18
Which one is better?
19
Continued…
• You can completely rely on a public network
for its intact consensus ( Proof-of-work)
system.
20
Benefits of using Blockchain
Following benefits of Blockchain we have:
• Distributed
• Secure
• Transparent
• Immutable
• Accessible
Continued…
22
Continued…
Immutable: Once data recorded in the block can
not be changed.
Accessible: Allows different parties to share
information leads to smooth and fast flow of
data.
23
Next Class
• Architecture of blockchain.
24