Directed Acyclic Graph (DAG) vs Blockchain

Mohammadreza Ashouri
3 min readSep 22, 2022

--

What is DAG?

A Directed Acyclic Graph (DAG) is a particular data structure class connecting various information elements. We can imagine as DAG protocol as a sequence of nodes and edges connecting them. The edges are unidirectional, implying that info cannot move in opposite directions. Any information in the DAG cannot move back to its source if we follow the graph’s direction. Hashgraph is an instance of a distributed ledger technology that uses DAGs to create an asynchronous Byzantine Fault-Tolerant consensus.

DAG vs Blockchain (Blockwiki)

Distinctions Between DAG and Blockchain

One of the differences lies in the data structure so that the validation process is parallelized in DAG, which results in higher throughput than blockchain.

Whereas the blockchain requires miners’ proof of work on each transaction, the DAG gets around this by removing the concept of block altogether. Instead, DAG transactions are linked to another, meaning one transaction verifies the next, and so on. These links are where the term DAG comes from, just like blocks getting hashed are where the blockchain receives its name.

Blockchains let one to trace down any record kept in a ledger’s account, though their sequential structure impedes their transaction throughput.

On the other hand, DAG works differently. DAG indeed resembles a flow chart where all points are headed in one direction. We can analogize a DAG to a file directory structure where folders have nested subfolders (similar to a tree).

As a blockchain grows over time, nodes will need more storage capacity and higher bandwidth (volume growth) to keep up-to-date with the transactions counted in the ledger. This means higher costs, and we may have unwanted centralizations due to miners’ existence in the blockchain.

DAG Advantages

DAG is a new protocol as much as blockchain technology is. However, many have touted its uniqueness as even more revolutionary. Here are some of the inherent advantages of this new technology.

High Scalability

Scalability is a challenge in most Proof of Work (PoW) blockchain networks. Continuous expansion of new transactions can deter the decentralization principle that maintains the network. In order to achieve scalability in a sound blockchain network, the number of nodes may also be needed to increase. This is always not practicable and, as such, leads to raised block times as miners are overwhelmed.

DAGs solve these scalability problems and suggests satisfactory throughput as they are not limited by block times. DAGA can process more transactions per second (TPS) compared to a traditional blockchain.

No Block Time!

High transaction speed is one of the significant benefits of a DAG. As described earlier, any user can broadcast transactions on the network and get a confirmation simultaneously. A typical blockchain network has a time-lapse or waiting period between when a transaction is logged and when it is confirmed. This is known as block time. These block times are non-existent in a DAG system, eradicating all forms of delays. Users can also register as many transactions as they like, provided elder transactions are validated.

No Mining

DAGs are free of mining. While PoW is not harmful in itself, its lack donates to the efficiency of DAGs in registering transactions.

Energy Efficiency

DAG projects or protocols do not use the PoW consensus mechanism with its high energy consumption. This has placed all DAGs as more environmentally friendly alternatives than PoW-powered blockchains.

Cost Efficiency

Using DAGs has proven more cost-effective than the significant public blockchain options today. The protocol has no miners that must be incentivized before transactions can be confirmed. This reduces the overall pressure and encourages adding more transactions without the fear of increased charges.

The energy efficiencies of DAGs are significant as climate change narratives are becoming a concern worldwide.

Potential Issue in DAGs

DAGs are unique in their ways, and they solve most of the inconsistencies of blockchain technology. However, they also have some drawbacks; DAG protocols are not always wholly decentralized. Many of these protocols rely on third parties to bootstrap the system. These third parties generate centralization and can therefore restrict the system’s overall security. This is a drawback when compared to protocols that thrive in blockchain ecosystems.

--

--

Mohammadreza Ashouri

Mo has a Ph.D. in Compter Science. Mo specializes in Backend Programming and Security.