BitcoinLightning NetworkTech
Trending

What the Heck is Lightning Network Anyway? Explained (With Pulled Pork Sandwiches)

2017 was the year Bitcoin gained mainstream attention, it was also the year that its biggest weakness was discovered: Scalability. The Bitcoin network was strained to the limit by millions of new users, resulting in long transaction times and high fees.

A new change to the Bitcoin protocol called the Lightning Network may solve these issues for good, but it has generated a fair amount of controversy.

Unfortunately, there are a lot of people opining on this issue who don’t quite have the facts right. That’s why today we’re going to cover— in plain English— what the Lightning Network is, how it works, and how it may change the bitcoin user experience forever.

Why do we need the Lightning Network? What’s wrong with Bitcoin?

Bigger blocks take longer to transmit across the network, and longer to verify, this means it takes longer for other nodes to receive and verify a block before starting on the next one.

The original vision for Bitcoin outlined in Satoshi Nakamoto’s white paper was a form of digital cash running on an electronic peer-to-peer (P2P) payment system.

This “cash” could be sent quickly and directly to the intended recipient, anywhere in the world, without any intermediary (like a bank) taking a cut of the transaction for itself.

Now, if a network like this is going to be used all over the globe, it must be able to handle global levels of transaction volumes. This is where the limits of Bitcoin becomes apparent.

On a typical day, the VISA network processes around 5000 transactions per second, but can handle up 65,000. In December of 2017 when the whole world was focusing on bitcoin, the network slowed to a crawl.

The massive influx of new bitcoin users strained the network to a level never seen before, resulting in individual transactions taking over an hour to complete, and transaction fees as high as $20 or 30 USD were not uncommon.

Getty Images

Someone engaging in a large and rare purchase (real estate, for example) might be willing to tolerate this, but this is clearly a deal-breaker for smaller, everyday transactions like buying a cup of coffee. Peter Thiel however might argue that Bitcoin is the Digital Equivalent of Gold, and who in their right mind would spend gold?

If bitcoin is ever going to gain mainstream acceptance, this scalability issue must be resolved. But the question remains; how to actually do it?

During this increased time, whoever found that block already knows it’s legit and gets a head start on the next block. This means more blocks, more bitcoin, goes to the larger miners. This is one method by which larger miners benefit from larger blocks.

There have been several proposed solutions, such as increasing block size (which we’ll talk about later), but the solution that has gained the most acceptance for BTC is the Lightning Network.

What does the Lightning Network do? How does it work? 

The central problem of bitcoin is the network is congestion; it takes the miners too long to verify transactions and add them to the block chain, and it can take a long time for the record of the transaction to be added, resulting in long delays.

Since it is these problems that make BTC unacceptable for everyday use, a unique workaround was proposed: what if those small transactions, like the aforementioned coffee purchase, did not have to be added to the main blockchain as they occured? What if there was a way to handle such transactions “off chain”, and then condense all those records before adding them to the main blockchain, so it didn’t congest the network as much?

That, right there, is the basic idea behind the Lightning Network: handling smaller transactions in a separate, parallel, payment channel between the two parties, and then adding record of their transactions to the main chain later. Confused? Don’t worry, let’s look at an example:

(Soon you’ll be buying these with BTC.)

Let’s say there is an office worker named Jim who likes to buy pulled pork sandwiches from a café near his office. This purchase would probably only be a few dollars, so using BTC in its current form wouldn’t make much sense. It is possible that Jim might pay transaction fees that are higher than the cost of the transaction itself.

Here’s where the Lightning Network comes in: in this scenario, a new, off-chain payment channel is created between Jim and the café. A “multi-signature wallet” is created in this new payment channel, and one of both parties deposit funds into it. You can imagine it almost like a piggy bank, or a safe that both Jim and the café have the combination to open. A balance sheet is created within this multi-signature wallet which lists how much each party holds within this “safe”.

For example, if Jim deposits 0.010 BTC and the café deposits 0.000 BTC, then the balance sheet will reflect those balances for each party. Now, Jim wants to buy his sandwich from the café for 0.005 BTC. When this happens, both parties sign the ledger with their private keys to verify the transaction, and the ledger is updated to reflect that Jim’s current balance is now 0.005 BTC, and the café’s balance is now 0.005 BTC.

Source: Simply Explained

When Jim makes another purchase, the sheet is updated and balances adjusted again. Jim can continue making purchases for as long as he holds a positive balance in the payment channel.

Now what happens when they stop transacting? The latest version of the balance sheet, which has been signed by both Jim and the café, is transmitted back to the bitcoin network. Miners then verify the signatures on the balance sheet, and the funds are released to both parties.

Everything described above, even if there were dozens of individual purchases, is recorded on the main blockchain as only two transactions: one to open the payment channel, and another to close it.

If this all sounds like a lot of work, don’t worry— this all happens automatically behind the scenes. The actual user experience of the Lightning Network would simply manifest itself as shorter transaction times and lower fees. There are no additional steps that must be completed manually.

Security

Now with all this talk of off-chain balance sheets, you might be wondering whether Jim or the café might try to cheat the other by closing the channel and transmitting an earlier version of the balance sheet back to the main blockchain. Luckily, the Lightning Network has built-in protections against that.

Whenever the balances in the multi-signature wallet are changed, the balance sheet is automatically adjusted and signed with both parties’ private keys. Only the most recent version of the balance sheet is recognized by the network as valid. Any time BTC changes hands on the private channel, all the previous balances are discarded.

So, does this mean you need to open a new off-chain payment channel every time you want to use BTC for small purchases?

Not exactly. Here’s where things get interesting…

What’s really amazing about the Lightning Network is that you don’t NEED to open a direct off-chain payment channel with everyone you wish to transact with.

Let’s expand on our scenario with Jim and the café. Jim is always talking about how great those pork sandwiches are, and his friend Julia now wants to try one. So, does Julia need to open a new off-chain payment channel to buy from the café using BTC?

Maybe. Maybe not. If she has exchanged BTC in the past with Jim, the Lightning Network will relay the money from Julia to Jim. and from Jim to the café, instead of opening a new channel between Julia and the café.

The Lightning Network remembers who has opened payment channels with whom in the past. When you use it, the BTC hops from person to person in the most direct way possible. There might be one step, or two or more steps. The network will seek out the most efficient route possible to get the BTC from Person A to Person B— meaning that it will always choose the path with the least number of steps.

Source: Bitcoin News

It is kind of like how a cellular network operates: when you place a call, your phone connects to the nearest cell tower, and the signal hops from tower to tower in the most direct path possible that will connect you to the person you are trying to call.

Does this mean Julia’s BTC temporarily ends up in Jim’s wallet, or that Jim can steal it en route to the café? Not at all. Jim will never even know this happened. It all happens automatically in matter of seconds, and since Julia and the café’s keys have both signed the balance sheet, only they can access the funds.

At the end of the day, what this means is the bitcoin could finally become usable for everyday small transactions, and handle them at a volume comparable to centralized services like VISA and MasterCard.

Why such a complicated solution? Why not just increase the block sizes?

Increasing more lanes is a dead end.

Not all everyone in the crypto community thinks this is good idea. Many have argued that it is unnecessarily complicated, and that an on-chain scaling solution like increasing the size of the blocks is a better way. This is the approach Bitcoin Cash (BCH) has taken, by increasing block size to 8MB, and more recently, to 32MB.

While BCH does have very fast transaction times, Lightning supporters aren’t buying the hype.

There are two arguments against increasing block size: the first is that it may unintentionally lead to a centralization of the bitcoin network, since it drives the costs of scale onto node operators. This will, over time, lead to ever-increasing centralization of mining and node ownership since only the wealthy could afford to keep doing it. This would defeat the whole purpose of creating a decentralized digital currency, since only those few people or entities with enough resources to spend on these activities would gain control of the network.

The second, closely related argument against bigger blocks is that it would be like relieving traffic congestion on a road by adding more lanes. It will work for a while, but sure enough, within a few years, the traffic is now just as slow as it was before, and it’s time to add even more lanes. Bitcoin is only going to become more popular with time, so the traffic load on the network is only going to go up.

Some have argued that expanding block size (as was the case with the BCH hard fork) will work for a time, but sooner or later you’ll have to expand it again. And again. And again.

If you stick with this approach, the network might eventually require blocks in the gigabyte range. Imagine, a 4 GB block created every ten minutes. That’s 24 GB and hour X 24 hours in day for 576 GB added to the blockchain every day. Multiply that by 365, and you have 210.2 TB per year.

So you’re ready to buy your first Bitcoin. Where to start? First, you got to set up your exchange account by creating an account and submitting your verification details. Once that is done, you’ll be able to send USD from your bank account into the exchange to purchase BTC. Read More…

At this point, the average person is not going to be able to host a node due to the enormous processing power that would require.

You would essentially have to build a whole data center just to host a node, and again, only very wealthy people and companies would have the resources to do so— and just like that, you have unwittingly recreated the centralized financial system.

The Lightning Network, supporters argue, avoids all these problems.

What are some other misconceptions people might have about the Lightning Network?

1) The process of how the Lighting Network just too complicated, and no one will want to do it. None of the steps described here are performed manually— it would be ridiculous to expect anyone to want to do all that. You don’t need to manually open those off-chain payment channels, it will just happen. This is all handled instantaneously “under the hood”. If successful, the actual user experience will be quite effortless.

2) Lightning Network node operators might become subject to anti-money laundering (AML) regulations. This is extremely unlikely to happen, because AML regulations typically only apply to LARGE transactions, which are not what the Lightning Network is designed for.

The Bottom line:

This is potentially a total game-changer for BTC, and could make mass adoption much faster. The Lightning Network beta is currently running on the bitcoin main network, and is ready to use for those who want to see what the future of daily cryptocurrency use might look like.

Bitcoin software is complicated, and any attempt to explain it in so short a space oversimplifies the technology. I encourage you to delve deeper into existing research to fully understand just how revolutionary Nakamoto’s White Paper was by checking out One of – if not the most – comprehensive resources for learning about Bitcoin with over 20 categories ranging from history, to buying BTC, setting up a wallet, technical information, mining, security, and trading: CoinZodiaC.com/bitcoin

Show More

3 Comments

  1. Another method is ASICboost, which is neutralized by Segwit. This “exploit” gives ASIC miners using it an energy use advantage over those who don’t, and the technology is protected by patent. Rumor is that Bitmain produces chips capable of it, but have denied using it themselves. This isn’t so much ‘benefitting by larger blocks’ but benefitting from not having segwit.

    This is why the BCH miners are both against segwit and for bigger blocks. They have a huge advantage in that system. They are mostly big Chinese miners.

  2. To sustain the current traffic of bitcoin we need 8MB block and you get low fees transaction which are super fast etc.. everyone is happy right?
    Fast forward 2 years in the future, bitcoin is a bit more mainstream a lot of people starts trading it, invest in it. We are seen as MUST have asset the traffic had increased 10 folds… 8MB -> 16MB -> 32MB -> 64MB -> 128MB -> 256MB -> 512MB -> 1024MB -> 2048MB -> 4096MB
    It Never Ends.

  3. I don’t think the regular average joe will run a node in his house just for “fun” or to mine bitcoin. With such Big Blocks, you’re creating centralisation of nodes and only big companies can run them. So you need a “bank” to run your nodes ( hold the ledger of all transaction ) and we came full circle. We just recreated another form of a central banking system.

Back to top button