In life, the most direct path is not always the fastest, the shortest, or the one that involves the least effort. There can always be obstacles. The same goes for the Lightning network, which functions as a second layer of Bitcoin, and through which hundreds of bitcoins are sent between thousands of nodes with channels open to each other.
In that huge interconnected network, satoshis (the smallest unit of bitcoin or BTC), travel to their final destination, leaning to choose the shortest, fastest or cheapest way in commissions. But what if we can use all these options at once? Will it be possible to travel several paths at the same time to reach the same common goal? It seems an approach to quantum physics, but with the Lightning network it is possible to fulfill this thesis.
To achieve this, researchers propose a mathematical and probabilistic solution that allows estimating which are the best routes of the Lightning network to send bitcoins. But they also propose split that payment and send your fractions separately, testing live which are the best available routes to consolidate such a transaction.
On July 13 was published the document “Optimally Reliable & Cheap Payment Flows on the Lightning Network“or, in Spanish,” Optimally reliable and cheap payment flows on Lightning Network”. This is the work of researchers René Pickhardt and Stefan Richter, published openly (open source) and was partially sponsored by the Norwegian University of Science and Technology (NTNU), as well as reviewed by other specialists (peer review).
All roads come to Bitcoin
Andreas Antonopoulos, Bitcoin educator, and Rene PickhardtLightning developer, recently participated in an episode of the podcast WhatBitcoinDid, moderated by Peter McCormack, where they talked about Lightning’s scalability and about this specific solution, among other topics.
Antonopoulos, known for simply explaining complex Bitcoin concepts, claimed that this would be one of the biggest innovations of the moment, and that it would allow sending payments potentially larger than what is usually sent in Lightning.
For a year there has been a technology in Lightning Network called Multi-Route Payments (Multi-Path Payment). With this, instead of sending payments through a set of Lightning channels or a single route, now what we can do is divide them into small fractions and send them through different channels and routes.
( … ) How do you divide this payment? Which channel to use to send all fractions? These are the questions, the problem of getting the best possible route, which are the basis of the enormous innovation that René (Pickhardt) has achieved with his research (…).
Andreas Antonopoulos, Bitcoin divulger.
Multi-route payments were reported by CriptoNoticias in late 2019, as a solution that allowed sending a payment across multiple channels with multiple users as its ultimate goal.
But now, what you’re looking for is use multiple channels to reach a common goal, or a single final direction. This is done for the purpose of sending large amounts of bitcoins using each and every one of the best options or channels available, when there is only one single recipient of the payment.
For his part, René Pickhardt explained that he was very surprised when, in a simulation, he noticed that he could send a large amount of bitcoins through Lightning, thanks to the results of the algorithm he designed to compute which are the best channels to use to trace the payment route.
Pickhardt argued that the larger is the payment in bitcoin, the greater the probability that Lightning cannot process it, due to the limited capacity of the channels.
Lightning network channels have the ability to send or receive as many bitcoins as their nodes have deposited. In September 2020, CriptoNoticias reported how a Lightning channel with a capacity of up to 5 bitcoins had been created, implying that this amount can be received or sent through it without problems, when previously it could only be sent on-chain, that is, over the Bitcoin main chain.
Then, in the simulation model, Pickhardt noticed how, at the time of making a payment, a user chose the channel that charged the lowest commission. What the researcher proposes is to use the probability theory and probabilistic functions to optimize the search for” the most likely to be successful routes ” to send the payment.
Antonopoulos commented on the podcast that he found it fascinating how you can “scatter” a payment or “flood” the Lightning network with transactions. Pickhardt explained that this is a mathematical problem of flows, so it was right to refer to this as a” flood ” of payments through network channels.
What we did was we divided the amount into 250 different fractions, of very small amounts, and we sent them to someone. When we created these multi-party payment streams (MPP), and sent them, we found that 75% of the balance sent arrived at its destination on the first attempt, the rest was returned to us. What we did was use the information collected with the confirmed and rejected payments, to adjust our estimate on the state of the network, and then run the second round of payments. In total I had to do this in four rounds in order to be able to send these bitcoins on the Lightning network, and I don’t think anyone has done it before.
René Pickhardt, Developer.
For his part, Antonopoulos pointed out that if we wanted to send 0.5 BTC on the Lightning network, to give an example of a large amount for this second layer, it would be better to divide the payment into 20 parts and pay less commission, than to do it in two parts and pay more.
A method still in the experimental phase
At the moment there are no applications that integrate this method as part of their native functions, but it is expected to continue to develop in the future.
Pickhardt receive from Antonopoulos and McCormack a donation of EUR 10,000 each, as support to continue their journey as a Lightning developer.
Regarding Lightning, during the month of last June the network exceeded its numbers in terms of channels and nodes available, as well as the amount of circulating bitcoins, CriptoNoticias reported. There are currently more than 22,830 nodes, 56,600 channels and 1,840 BTC circulating in the Lightning network, according to 1ML.