Untangling IOTA – What’s a Tangle?

, ,
IOTA TANGLE SERIES

IOTA (or the Internet of Things Application) is both an open-source distributed ledger and cryptocurrency that entered the crypto market back in 2016.  At first glance, it may seem like IOTA is just another token on the market or yet another attempt at creating an open-source distributed ledger (just like Bitcoin, Ethereum, etc.).  However, taking a closer look reveals the truly revolutionary abilities that IOTA brings to the crypto world. 

IOTA Tangle Series

In this series, we plan to roll up our sleeves and dive into the details of how IOTA works and why it’s presented such a revolutionary design to the crypto world.  We’ll start with the fundamental building blocks in this post and move onto some of the practical applications in those that follow.  If you really want to understand how IOTA works from a mathematical and functional perspective, the Whitepaper is an indispensable resource to read and study.  The math behind the Tangle is quite impressive and complex…and it’s also very complicated.  I’ll include some links at the bottom of the post that you can use to further increase your knowledge.

Okay, enough introducing, let’s get to it!

While not the only novel facet of IOTA, the Tangle is such a radical distinction from the standard cryptocurrency / ledger currently in use by most tokens that it only makes sense to start here and continue to build.  Great, so…what’s the Tangle?  Simply put, the whitepaper defines the Tangle as “a directed acyclic graph (DAG) for storing transactions”.  Duh, it’s just a DAG!  Just kidding, let’s take a look at what DAG’s are and then try to understand why IOTA decided to use them. 

Tangle Graph Theory

There are several steps to get us to a DAG, so keep your geek hat on for a second and we’ll be back to planet Earth in just a minute.  To get started, mathematics has many different facets (more than just the algrebra, geometry, and maybe calculus that you took in high school or college); graph theory makes up a part of mathematics as a whole.  No, graph theory isn’t about studying graphs like y=x2 or cos(x); instead it’s about modeling pairwise relationships between child objects and their relationships to parent object(s).  Below is a simple picture of a graph:

Undirected graph

Figure 1:  A simple, undirected graph.

            This type of graph is referred to as an undirected graph.  There are no directional relationships between the points in the graph – instead they just exist together and link to form an entire structure.  This is different than what’s used in the Tangle; see below:

Directed Graph

Figure 2:  A simple, directed graph.

Notice the difference with this type of a graph – there’s a direction between the points (i.e., they are an ordered set of points).  The top left point connects to the top right point in a specific direction, whereas the top right point connects bidirectionally with the bottom point.  This forms the first foundation in understanding a directed acyclic graph.

            Alright, so we understand the first part of the DAG; what about the second part?  What does it mean for a graph to be acyclic?  Let’s take the strategy we used above and first define a cyclic graph.

Directed Cyclic Graph

Figure 3:  A simple, directed cyclic graph.

In this graph, we see that there is a logical ordering that produces a single cycle.  In other words, we can start at the top point and proceed around the structure, ending again at the starting point.  This can continue on and on as necessary; hence, the term “cycle” is fitting.

Directed Acyclic Graph

Figure 4:  A simple, directed acyclic graph.

There’s a difference with this graph.  Can you spot it?  There are no directed cycles such that one could start at a given point, loop around the graph, and end back up from where they started.  Another important distinction in a DAG – it always follows a topological ordering.  This means every time a new path is formed between nodes, it always goes from earlier to later in the sequence (or simply it doesn’t go “backwards” in time).  This helps us finish out our basic understanding of a directed cyclic graph.  Let’s put it all together.

  • A graph is an abstract concept that structures a set of objects together with some relationship among the objects.
  • A graph can be directed if the order between any two successive nodes in the graph matters.  In other words, A à B matters and doesn’t necessarily equal A ß B. 
  • Finally, a directed graph can be acyclic if there is no succession of hops along the graph that forms a cycle (which would allow one to start and end at the same node).
  • A directed acyclic graph always follows a topological order (such that it only ever makes connections “forward” in time and never “backward”). 

Tangle Vertex

It’s important to note that each time a transaction enters the network, a new “vertex” is added to the Tangle (where a vertex is a blue circular node above in Figure 4).  The edges that connect any two transactions are the approvals on the ledger.  Putting these two ideas together, a graph can be formed that relates transactions (vertices) with their corresponding approvals (edges). 

Phew, you might need to take a break after that one.  All that being said, this is the structure IOTA uses in its ledger to record and validate transactions.  This is obviously much different than a standard blockchain, but how?  A blockchain is a synchronous approval mechanism; this means that the longest (most trusted or most often validated) line of blocks stays on the blockchain and each block is added one after the other after the other.  Any forks or side branches eventually get orphaned and are discarded, no longer of any use even though work was done to validate the transactions they held.

Concept of the Tangle

While the blockchain is a synchronous set of blocks stacked one after the other, the Tangle has no concept of this rigid synchronicity.  Instead, the system acts asynchronously and can have many forks and branches that all converge over time.  The main impetus for this decision was scalability of the distributed ledger.  Because each node participates in the validation process during the performance of a transaction, the network of validated transactions continues to strengthen while staying nimble.  This allows computationally bounded devices (such as IoT devices) to participate in the network (no need for racks and racks of custom ASICs to validate transactions by calculating terahashes of computations). 

In addition, transactions on the network are “free” in that they require neither the sender nor the receiver to pay any MIOTA (IOTA’s token).  Instead, each transaction requires the node to perform two validations of other transactions within the network.  The choice of these transactions is outside the scope of this article, but feel free to look at the Whitepaper if you really want to know what’s going on here (especially starting at section 2).

Tangle Versus Blockchain

There are few more important distinctions to make with the Tangle and how it relates to a standard blockchain:

  • The Tangle provides virtually unlimited throughput (as opposed to, say, Bitcoin with about a 10-minute block production schedule or Ethereum which produces about 10-12 blocks per second).  Because of its asynchronous nature, the Tangle can proceed extremely quickly and has no programmed block schedule.
  • There are no mining fees in IOTA as there are no miners.  Each node must verify two transactions every time it produces a new transaction.  This allows the system to send all of the MIOTA specified in the transaction payload without having to worry about miners’ fees or higher fee payment if a quicker verification of the transaction is desired.
  • Because there are no miners in IOTA, there are no incentives (other than perhaps malicious intent) to slow the network down.  Typically, this is done to raise fees, which really goes against the decentralized nature of most cryptocurrencies.  Rather, nodes are incentivized to perform quickly as their transaction can be further validated after being added to the Tangle.

IOTA Education

If you made it this far, you deserve a medal of bravery.  IOTA is a complex concept to understand, but you find more and more nuggets of information each time you delve into the topic.  Still want to learn more?  Check out a few of these articles:

  • Here’s an extremely thorough look at directed acyclic graphs
  • We referenced it above earlier, but in case you missed it the IOTA Whitepaper is a great, thorough read on the topic.  While it mainly focuses on the Tangle itself, there are quite a few ancillary details that can be gleaned during a focused read.
  • Here’s a bit more information on IOTA from a high-level perspective.
  • Meet the Tangle.  We promise it doesn’t bite (yet).

This is only the beginning of our detailed exploration of IOTA.  We plan to visit more of the specific core concepts and applications in the future.  In the next article, we’ll take a look at IOTA’s overall place in the IoT world and how it plans to become the de facto token / ledger for transactions among these devices.  Until then, happy reading!