UNIT IV:
Welcome to Unit IV of our tutorial series! In this section, we will dive into the
fascinating world of Ethereum and IOTA, explore the real need for mining,
understand consensus in blockchain, and solve the Byzantine Generals Problem.
Why do we need mining?
Maintaining Security Incentivizing Distributing New Coins
Participation
Mining ensures the integrity Mining is the process
of the blockchain, Miners are rewarded with through which new
preventing fraud and cryptocurrency for their cryptocurrency is released
double-spending. computational efforts, into circulation.
driving network
participation.
Ethereum
Ethereum is a Blockchain network that introduced a built-in Turing-complete programming language that can be used for
creating various decentralized applications(also called Dapps).
The Ethereum network is fueled by its own cryptocurrency called ‘ether’.
• The Ethereum network is currently famous for allowing the implementation of smart contracts. Smart contracts can be
thought of as ‘cryptographic bank lockers’ which contain certain values.
• These cryptographic lockers can only be unlocked when certain conditions are met.
• Unlike bitcoin, Ethereum is a network that can be applied to various other sectors.
• Ethereum is often called Blockchain 2.0 since it proved the potential of blockchain technology beyond the financial
sector.
• The consensus mechanism used in Ethereum is Proof of Stakes(PoS), which is more energy efficient when compared to
that used in the Bitcoin network, that is, Proof of Work(PoW). PoS depends on the amount of stake a node holds.
.
Working Process of Ethereum
Ethereum implements an execution environment called Ethereum Virtual Machine (EVM).
• When a transaction triggers a smart contract all the nodes of the network will execute every instruction.
• All the nodes will run The EVM as part of the block verification, where the nodes will go through the transactions
listed in the block and runs the code as triggered by the transaction in the EVM.
• All the nodes on the network must perform the same calculations for keeping their ledgers in sync.
• Every transaction must include:
• Gas limit.
• Transaction Fee that the sender is willing to pay for the transaction.
• If the total amount of gas needed to process the transaction is less than or equal to the gas limit then the transaction
will be processed and if the total amount of the gas needed is more than the gas limit then the transaction will not be
processed the fees are still lost.
• Thus it is safe to send transactions with the gas limit above the estimate to increase the chances of getting it processed.
IOTA
IOTA (MIOTA) is a distributed ledger designed to record and execute transactions between machines and devices in the
Internet of Things (IoT) ecosystem. The ledger uses a cryptocurrency called MIOTA to account for transactions in its
network.
Working Process
• IOTA uses a unique data structure called the Tangle, which is a Directed Acyclic Graph (DAG) that enables feeless
transactions and near-instant confirmation times. The Tangle operates differently from traditional blockchain technologies,
which rely on miners to validate transactions and create new blocks.
• In the IOTA Tangle, each transaction must confirm two previous transactions before it can be confirmed itself. This
creates a web-like structure of transactions that are all interconnected and form a mesh network of data and value that
transfers. Each node in the network is responsible for confirming two other transactions, making the network more secure
and efficient as more users participate.
• Because there are no miners in the IOTA Tangle, there are no transaction fees are associated with sending transactions.
• This makes it well-suited for microtransactions in IoT applications where small amounts of data or value are exchanged
between the devices.
.
• Additionally, Because the Tangle operates without miners, it is more energy-efficient than traditional blockchain
technologies.
• One potential downside of the IOTA Tangle is that it can be more susceptible to certain types of attacks, such as the
double-spending attack.
Bitcoin Mining
Bitcoin mining refers to the process of validating and recording transactions on the Bitcoin network. The primary
purpose of Bitcoin mining is two : validating transactions to prevent fraud and adding new blocks to the blockchain,
thereby creating new Bitcoins in a decentralized manner.
Key Takeaways:
• The process of bitcoin mining involves the verification of new transactions against the Bitcoin network, which
results in the production of new bitcoins.
• Bitcoin mining is the process by which Bitcoin transactions are validated digitally on the Bitcoin network and added
to the blockchain ledger.
• It is done by solving complex cryptographic hash puzzles to verify blocks of transactions that are updated on the
decentralized blockchain ledger.
• Solving these puzzles requires powerful computing power and sophisticated equipment. In return, miners are
rewarded with Bitcoin, which is then released into circulation hence the name Bitcoin mining .
Consensus:
• A consensus algorithm is a procedure through which all the peers of the Blockchain network reach a common
agreement about the present state of the distributed ledger.
• In this way, consensus algorithms achieve reliability in the Blockchain network and establish trust between unknown peers
in a distributed computing environment.
• Essentially, the consensus protocol makes sure that every new block that is added to the Blockchain is the one and only
version of the truth that is agreed upon by all the nodes in the Blockchain.
• The Blockchain consensus protocol consists of some specific objectives such as coming to an agreement, collaboration,
cooperation, equal rights to every node, and mandatory participation of each node in the consensus process.
• Thus, a consensus algorithm aims at finding a common agreement that is a win for the entire network. Now, we will discuss
various consensus algorithms and how they work.
Proof of Work (PoW):
• This consensus algorithm is used to select a miner for the next block generation. Bitcoin uses this PoW consensus
algorithm. The central idea behind this algorithm is to solve a complex mathematical puzzle and easily give out a solution.
• This mathematical puzzle requires a lot of computational power and thus, the node who solves the puzzle as soon as
possible gets to mine the next block.
Proof of Stake (PoS):
• This is the most common alternative to PoW. Ethereum has shifted from PoW to PoS consensus. In this type of consensus
algorithm, instead of investing in expensive hardware to solve a complex puzzle, validators invest in the coins of the system
by locking up some of their coins as stakes.
• After that, all the validators will start validating the blocks. Validators will validate blocks by placing a bet on them if they
discover a block that they think can be added to the chain.
Delegated Proof Of Stake (DPoS):
• This is another type of Proof of Stake consensus algorithm. This type of consensus mechanism depends on the basis of the
delegation of votes.
• The users delegate their votes to other users. Whichever user then mines the block will distribute the rewards to the users
who delegated to that particular vote.
Consensus as a Distributed
Coordination Problem
1 Proof of Work (PoW)
Explore how PoW allows participants to
reach agreement in a trustless
Proof of Stake (PoS) 2 environment.
Discover how PoS replaces
computational work with participants'
stake in the network. 3 Delegated Proof of Stake (DPoS)
Learn how DPoS empowers
stakeholders to delegate their voting
power to trusted representatives.
The Byzantine Generals Problem
A Battle of Trust Trust and Betrayal Achieving Consensus
Explore the challenges of Learn how Byzantine failures Discover the elegant solutions to
coordinating actions in a affect consensus in blockchain the Byzantine Generals Problem.
distributed system. networks.
Private or Permissioned Blockchains
Private or permissioned blockchains are blockchain networks that restrict access to authorized participants
only. Unlike public blockchains, which are open to anyone, private or permissioned blockchains require
permission to join and participate in the network.
These types of blockchains are often used by organizations and enterprises that want to maintain control over
their blockchain network and data. They offer increased privacy, scalability, and efficiency compared to public
blockchains, making them suitable for various use cases such as supply chain management, financial
transactions, and data sharing among trusted parties.
Hyperledger
Hyperledger provides the platform to create personalized blockchain services according to the need of business
work. Unlike other platforms for developing blockchain-based software, Hyperledger has the advantage of
creating a secured and personalized blockchain network.
• It is created to support the development of blockchain-based distributed ledgers.
• It includes a variety of enterprise-ready permissioned blockchain platforms.
• It is a global collaboration for developing high-performance and reliable blockchain and distributed ledger-
based technology frameworks.
Layers in Hyperledger
Hyperledger uses the following key business components:
• Consensus layer: It takes care of creating an agreement on the order and confirming the correctness of the
set of transactions that constitute a block.
• Smart layer: This layer is responsible for processing transaction requests and authorizing valid transactions.
• Communication layer: It takes care of peer-to-peer message transport.
• Identity management services: these are important for establishing trust on the blockchain.
• API: It enables external applications and clients to interface with the blockchain.
Need of the Hyperledger
• To enhance the efficiency, performance, and transactions of various business processes.
• It provides the necessary infrastructure and standards for developing various blockchain-based systems and
applications for industrial use.
• It gets rid of the complex nature of contractual agreements, as the legal issues are taken care of.
• Hyperledger offers the physical separation of sensitive data.
• It decreases the need for verification and enhances trust, thus optimizing network performance and scalability.
Currency, Token, and Campus Coin
Currency: The Tokenization: Campus Coin: A
Lifeblood of Reinventing Practical
Economies Assets Application
Money is more than just paper. Tokens enable the Experience the benefits of a
Discover the fundamental representation of real-world local currency within a campus
nature of currency and its assets on the blockchain, community, fostering a vibrant
function in modern revolutionizing the way we and sustainable economy.
economies. transact and invest.
Coin Drop Strategy for Public Adoption
1 Engagement and Excitement
Drive interest and enthusiasm by distributing free tokens to the public.
2 Educational Campaigns
Use the coin drop to educate and showcase the benefits of blockchain technology.
3 Creating a Network Effect
Expand adoption through the domino effect, as recipients interact and transact with the
ecosystem.
Currency Multiplicity and
Demurrage Currency
1 Multiplying Currency Possibilities
Discover the potential of multiple currencies coexisting in a blockchain ecosystem.
2 Exploring Demurrage Currency
Uncover the concept of demurrage currency, where money loses value over time to
encourage spending and circulation.
3 Building Economic Sustainability
Explore how demurrage currency fosters economic activity and reduces hoarding.