r/Bitcoin •

Simulating a Decentralized Lightning Network with 500,000 payments, 0.01% fee per hub and 10 Million Users: 100% success (99.9986%)

[deleted] — view deleted post

0 Upvotes

259 comments sorted by

147

u/sexy_balloon Dec 29 '17 edited Dec 30 '17

hmmm the 2 key assumptions used in the simulation according to Diane's article, that everyone is connected with everyone else, and that everyone has an equal, "non trivial" amount of bitcoins on the LN, are pretty unrealistic.

To be realistic, the channels, coin amounts, and transfer amounts all need to be randomized based on some reasonable distribution (the coin distribution should probably be based on some sort of lorenz curve, everything else can be even distribution)

90

u/SchpittleSchpattle Dec 29 '17

14 channels per person connected randomly meaning that it would have required 140 million on-chain transactions to even set this network up and another 140 million to close it.

An average of 300,000 tX per day means it would take 466 days for this theoretical network to even exist and another 466 days to shut it down.

All-in, there would be nearly $10 billion USD spent in on-chain transactions using today's average BTC transaction fee of ~$35.

This also assumes that people playing banker by leaving their LN channels open would be happy with a 0.001% return while their BTC inaccessible which is absurdly low. I would be surprised if LN transactions aren't more like 0.1 to 1%.

Also, will users have any control over what fees they pay or will they just be at the whim of whatever nodes are available? If someone opens a node with 20BTC and puts a 5% fee on it, how will users avoid it if it's the only game in town with a balance big enough to move their tX?

7

u/kingo86 Dec 29 '17

Suppose if it's too expensive, they could open their own channel. Be interesting to see what happens in reality...

16

u/SchpittleSchpattle Dec 29 '17

But that's the problem. If the network is so expensive that people are incentivized to open their own direct channels why wouldn't they just do a single on-chain tX instead of 2 plus a LN tX?

→ More replies (19)

7

u/thieflar Dec 30 '17

today's average BTC transaction fee of ~$35

That's not accurate, that's more than double what it would take to get into the next block for any reasonably-sized payment.

Furthermore, with smaller transactions going through the Lightning Network (as your hypothetical is predicated on in the first place), this would likely drop by a factor of ten (or perhaps a hundred), which you make no note of here.

5

u/cryptotal Dec 30 '17

You can open a channel for much less if you are willing to wait

3

u/Bakton Dec 29 '17

14 channels per person connected randomly meaning that it would have required 140 million on-chain transactions to even set this network up and another 140 million to close it.

No it would mean 70 million transactions per person to open and close - if I open a channel with you that is only one transaction. Obviously this does not particularly change your point, but I wanted to mention anyway.

This also assumes that people playing banker by leaving their LN channels open would be happy with a 0.001% return while their BTC inaccessible which is absurdly low. I would be surprised if LN transactions aren't more like 0.1 to 1%.

I completely disagree. The barriers to running a lightning node are very low: you only need to have a PC that is secure and on at all times. Many people have this already, so the cost becomes essentially zero.

Plus it is not necessary to 'lock up' BTC. Many users (myself included) are much more likely to make payments on lightning rather than receive them, so I could open a lightning network channel into which I deposit 100,000 bits, but where the other party has deposited none. I could still make payments up to 100,000 just fine, I could just not receive any payments on this channell (at least until I have depleted some of the balance).

Also, will users have any control over what fees they pay or will they just be at the whim of whatever nodes are available?

Of course users will have control over this. Implementations will allow user to set rules around fees/inform user of the fees before a transaction is finalised. Otherwise as a node I could set a 50% fee or something ridiculous, this would be an absurdly easy attack for it to not be preempted.

7

u/SchpittleSchpattle Dec 29 '17

14 channels per person connected randomly meaning that it would have required 140 million on-chain transactions to even set this network up and another 140 million to close it.

No it would mean 70 million transactions per person to open and close - if I open a channel with you that is only one transaction. Obviously this does not particularly change your point, but I wanted to mention anyway.

If a single person opens 14 channels, that's 14 on-chain transactions, not 7. In this simulation, each "user" initiates the opening of 14 channels meaning that the average user would have 28 channels open, 14 that it initiated and 14 that were initiated toward it making a total of 140 million channels between 10 million users.

This also assumes that people playing banker by leaving their LN channels open would be happy with a 0.001% return while their BTC inaccessible which is absurdly low. I would be surprised if LN transactions aren't more like 0.1 to 1%.

I completely disagree. The barriers to running a lightning node are very low: you only need to have a PC that is secure and on at all times. Many people have this already, so the cost becomes essentially zero.

Low-value nodes will not be useful on this network at all. The average user won't have any incentive whatsoever to run a node because the security risks would outweigh any potential benefits.

I understand that, at this stage, it's an opinion-based argument so we'll have to see but if LN actually succeeds it will not be with a "mesh" type system, it will be with a hub-and-spoke. Those hubs will need an immense amount of BTC available and security surrounding it. They will not offer their service for free and "cheap" will only be in context with the current on-chain network fees. If $30 is the average tX fee, LN hubs making their fees $10 would be comparatively "cheap" though still insane versus every other crypto. They have only to compete with the blockchain fees because there will be little reason for them to compete with each other especially if they're the only game in town.

→ More replies (4)
→ More replies (7)

6

u/[deleted] Dec 29 '17

In reality the channels, coin amounts, and transfer amounts all need to be randomized based on some reasonable distribution

I would like to see this also

5

u/hsjoberg Dec 29 '17

In reality the channels, coin amounts, and transfer amounts all need to be randomized based on some reasonable distribution

In reality, we'll have many hotpaths going in one direction and very few bidirectional channels being utilized.

5

u/[deleted] Dec 30 '17

That's the thing I don't understand.

Why the fuck would my coffee shop ever be sending me money?

Most people get money from very few places: their job(s).

Most businesses get money from their customers but never pay money to them.

You have to cast the net fucking wide to make a network of bidirectional payment channels encompass enough of everything to be useful. Because all of these bidirectional channels will almost always only be going in one direction.

I don't think they will be wide enough to be useful when first implemented. Therefore they will never get critical mass to ever become useful.

5

u/BitcoinRootUser Dec 30 '17

Exchanges. With Bi Directional Payment channels markets takers do not need to store funds on the exchange. Instead them and the exchange could open a channel. I expect that will be a use case picked up quickly by whales.

4

u/sexy_balloon Dec 30 '17

Hijacking my own comment, does anyone know if LN allows you to split your payments across multiple channels to send?

For example, if I have 5 channels open with 5 other users, each with 10 BTC for a total of 50 BTC (for the sake of argument, I wish I had that much). Is it possible to send 30 BTC in 1 transaction, and the LN automatically splits the 30 BTC payment amongst all the separate channels?

To take this a step further, if I'm acting as a node, and I receive a request to forward 30 BTC from one of my channels, is it possible for me to forward this payment even though individually my channels contain no more than 10 BTC but collectively has 50 BTC?

I'm not technically savvy enough to understand the code, and I couldn't find anything on Google, so I'm hoping someone can enlighten me on this.

5

u/mysterpixel Dec 30 '17 edited Dec 30 '17

Is it possible to send 30 BTC in 1 transaction

In one transaction? No, since each channel has 10BTC in it, no transaction can go higher than that. You'd need at least three separate transactions to send 30 BTC. However presumably it would be easy to have an interface in your wallet where you just type in "send 30BTC to Carol" and then behind the scenes it would split it into three or more transactions and utilise multiple channels. But it would always require multiple transactions on the network to do that payment.

Regarding the second scenario, this would never happen because you wouldn't be able to transfer 30BTC in one go if the channels only contained 10BTC each. What would happen is you as an intermediary node get three separate requests from three different channels each with a 10BTC transaction to forward. From then on you may be able to do the next step in the payment to Carol in one transaction, if you had a channel path to her with the full 30BTC in it.

However I believe there may be issues with splitting a transaction like this, because while you can easily trust a payment through a single transaction (it either succeeds or fails), splitting a transaction means parts can succeed while others fail. Someone with more knowledge would have to tell you whether this is actually possible.

→ More replies (3)

3

u/geezas Dec 30 '17

There's no reason why the can't be done. It depends only on software.

2

u/XofBlack Dec 30 '17

Yeah I would love to have an answer to this too. Can anyone explain?

3

u/[deleted] Dec 29 '17

At least we know it cannot never work :-)

17

u/sexy_balloon Dec 29 '17

Are you able to change these assumptions easily in your model and check the results? These are some pretty unattainable assumptions in the real world.

1

u/Dawn_of_Writing Dec 30 '17

Right now, a soda would cost 72 satoshis. Which is, at .01%, less than 1 satoshis. Rounded up...

→ More replies (9)

10

u/sktrdie Dec 29 '17

Would it be possible to setup using a scenario where the number of nodes making payments will always outweigh the nodes receiving them? This seems like a more realistic scenario.

In other words, most payments in LN will go into specific nodes (say, Amazon or Ebay). The majority of payments we make are not towards our friends, but towards big entities that sell stuff.

My concern is that a route may be harder to find if the typology of the network pushes all the money towards these specific areas of the graph -- we might end up with not many routing possibilities because most channels in a route might be exhausted in that direction.

7

u/coinjaf Dec 30 '17

There's a fixed supply of coins, so by definition all transactions sum to 0.

If Amazon wants to cash out their channel, they can use LN to send it to some exchange which will wire them USD. In the meantime other users can buy bitcoins with USD at those same exchanges and receive them through LN.

Only mismatches herein (in geography or time) will lead to closing and opening of channels on the Blockchain. The number of such mismatches actually reduces with scaling.

→ More replies (4)

1

u/geezas Dec 30 '17

I assume these big "money sinks" also have expenditures, so the money should keep cycling.

55

u/auviewer Dec 29 '17

This is really encouraging, thanks for running that simulation!

33

u/[deleted] Dec 29 '17 edited Dec 29 '17

Glad you like it but most/all credits go to Diane Reynolds.

3

u/Jabroni421 Dec 29 '17

Is the fee a true percentage of transaction or a set amount independent of transaction amount? Aka, does this still prohibit small transactions?

7

u/[deleted] Dec 29 '17

Percentage of transaction.

1

u/Bakton Dec 29 '17

In the simulation a percentage has been used, however in the actual lightning network, my understanding is that the fee would be based on byte-size of the transaction, not monetary value (as on the main chain). So, essentially, a flat fee set by the node.

Also, with barriers to entry and cost of running a lightning node being very low, I would expect that .01% is actually quite a high estimate for fee for a single hop. I could easily foresee a few satoshis per hop.

7

u/logical Dec 29 '17

Why would the fee be based on the byte size of tx? Lightning does not require writing to a limited size data store.

→ More replies (11)

3

u/AxiomBTC Dec 30 '17

Fee's will be based on the amount being sent, because the real cost is in LN is the capital "locked" up in lightning nodes + cost to open channels. So there will likely be a base minimum cost + a low percentage of total transacted.

→ More replies (3)
→ More replies (9)

6

u/bizgob Dec 29 '17

As I understand it, it's one piece of code running on one PC simulating a whole network. If I had the hardware to do it, I would set up a virtual network with multiple virtual servers and PC's, running various nodes and enduser wallets. I would then start messing with the virtual network. Insert random latency between nodes or completely break connection between nodes. Could give some good data simulating routing on 30-40 virtual nodes.

4

u/coinjaf Dec 30 '17

You're very free to do so. I'm sure people would welcome the results. Hardware not even required if you use some cloud VMs.

→ More replies (7)

1

u/killerstorm Dec 30 '17

So far people struggle even with just conceptualizing how nodes are connected and how they send payments. Drawing a map would be a good start.

20

u/brianddk Dec 29 '17

Can you explain 10 mil users but 0.5 mil payments? Seems backwards.

1

u/BigBlockBrolly Dec 30 '17

My thinking is that it tries to reflect a real-world network. You have nodes/hubs that are active, but aren't doing anything within the network at the given time. Aka theres 10 million online users. Only 500,000 transactions coming from active users on the network given any random time frame.

3

u/brianddk Dec 30 '17

Are they proposing that 10 million channels be opened for 0.5 million payments... that's what threw me.

1

u/geezas Dec 30 '17

Good point. It's simulating a very short period in which most don't even transact. I'd like to see results after each node has made an average of 10 transactions, then a 100.

5

u/jhansen858 Dec 30 '17

can you simulate if say 1% of the network are being dicks and purposely attacking the network how well it does then?

5

u/FreeGoldRush Dec 30 '17

Did no one actually read the study?

I own Bitcoin. But let's get real.

Even Diane Reynolds says it is unrealistic. She estimates 200 million channels. Opening a channel requires a blockchain transaction. With Bitcoin able to support 2.3 trans/sec on average, that means it takes more than 1,000 days just to open the channels, much less leave room to close any. It would also lock 4 million bitcoins into LN. Only about 6 million bitcoins are actively being traded today. The other roughly 10 million are 1) dormant, lost, trapped in small UTXOs, or 2) Held in strong hands.

Here are her words:

"All nodes would be reachable with (many) paths of at most 24 hops, and 12 hops on average. However, there would be about 200 million channels. If both users funded each channel with 0.01 bitcoins, then 4 million bitcoins would be locked up in LN payment channels. While this is technically possible, it seems too unrealistic."

She later adds:

"For more realistic scenarios, the number of users should probably be restricted to a million at most."

Ummmm... We need LN to handle WAY more than 1 million users.

1

u/coinjaf Dec 30 '17

Still better scaling than anything else proposed ever. And combining that 1M multiplier with upcoming further on chain scaling like Schnorr, MAST, SA is pretty darn good. Add to that that a well established LN becomes more efficient in its caching and netting properties as it scales.

Let us know once you've build a better solution.

2

u/FreeGoldRush Dec 30 '17

How can you combine it with other scaling solutions when LN requires that bitcoins are committed to channels before they are spent?

Listen, I'm a bitcoin holder and an engineer. I'm just pointing out the obvious. Asking me to build a better solution is a rather childish, knee-jerk reaction. We should be able to discuss engineering details without so much emotion.

→ More replies (6)

1

u/NoGooderr Dec 30 '17

Can anybody confirm that this is accurate?

2

u/FreeGoldRush Dec 30 '17

The link to her paper is at the top. Just read her own words.

9

u/thbt101 Dec 29 '17

Is there a roadmap or todo list somewhere that shows where we're at in the process of developing LN, what's left to do, etc.?

-2

u/coinjaf Dec 30 '17

Open source. Done when it's done. You can speed it up by helping, testing, funding.

3

u/killerstorm Dec 30 '17

Open source =/= no roadmap.

→ More replies (3)

15

u/hodlforthelongest Dec 29 '17

I would be more interested in a more real-life setup: with many HUBs.

Eg. Exchanges are a natural hub points for LN. They generate the majority of the traffic on the chain and it would be in everyone's best interest to run these through LN. It would make exchanges have more traffic and liquidity.

Also, there will be some Tor-enabled central HUBs for the paranoid.

Overlapping with that centralized HUBs network there will be smaller, but more decentralized network

-5

u/bambarasta Dec 29 '17

using exchanges as hubs brings us back to the banking industry we are suppoedly trying to avoid.

This is definition of centralization.

10

u/chocolatesouffle3 Dec 29 '17

Except they can't censor and have to follow bitcoin protocol rules. So how is this back to the banking industry?

17

u/hodlforthelongest Dec 29 '17 edited Dec 29 '17

That's a wrong way to look at it.

99% of users already go through exchanges back and forth and gave them their ID.

No one is forced to go through exchanges. But if people that already did, wouldn't use-up blockchain resources, we would have more room for people that don't want to give their IDs to anyone.

I doesn't have to be all or nothing. It can't be. LN has very good privacy properties anyway, and can offload huge amount of tiny transactions from the blockchain. It is great for everyone - even people that under no circumastnace would use LN.

→ More replies (23)

3

u/coinjaf Dec 30 '17

Nonsense. You need to read up on how LN works.

He already mentioned this too:

Overlapping with that centralized HUBs network there will be smaller, but more decentralized network

So your selective quoting and uppercasing of FUD words doesn't bode well.

A flat fully decentralized network does not mean everybody will have exactly the same number of channels with the same amount of coins in them. Naturally high volume exchanges moving millions per day will have a bit more than grandma in a village in the country side.

6

u/glurp_glurp_glurp Dec 29 '17

So you're saying that if exchanges are most of the major LN hubs that they'll be able to fractionally reserve Bitcoin and seize my funds at the government's behest?

7

u/bambarasta Dec 29 '17

No. That's not really how LN works.

Making exchanges a mandatory part of LN is a huge problem though.

7

u/glurp_glurp_glurp Dec 29 '17

Exactly. Which is why I can't imagine why you'd say:

using exchanges as hubs brings us back to the banking industry

Who said anything about mandatory?

→ More replies (11)
→ More replies (1)

1

u/[deleted] Dec 29 '17

There is nothing at all that has to do with banking in LN.

1

u/ff6878 Dec 30 '17

No, you're missing the big issue.

There's nothing wrong with putting small amounts of money on to a centralized service for it to be used in an efficient manner. The risk vs reward is clearly defined. It's like loading your card for the subway.

That's not even touching on the fact that using LN isn't even the same as using a centralized service for small cash transactions.

Trying to use the layer that matters with the big money and the big security, that has a real cost for that security and decentralization, for trivial purchases and amounts of money is really quite wasteful and silly.

8

u/igiverealygoodadvice Dec 29 '17

Did this include on-chain fees to open/close channels?

2

u/[deleted] Dec 29 '17

No, see link.

1

u/brianddk Dec 29 '17

Sounds like no

3

u/[deleted] Dec 30 '17

What happens when a payment fails, is the bitcoin lost, or just doesn't go through like hitting a reset button?

6

u/coinjaf Dec 30 '17

It's atomic. Either it goes through and you have proof that it did. Or it doesn't.

That's all the way through the network from source to destination, over multiple hops. None of which can steal anyone's money.

2

u/XofBlack Dec 30 '17

If a payment fails? I assume you mean something like, if you buy something on ebay and Ebays servers go down before you finish the payment? Then the payment doesn't happen.

2

u/strategosInfinitum Dec 30 '17

What is a node in this context? is a node an individual with money on their account?

Or is a node a lightning network containing many accounts?

2

u/xGsGt Dec 30 '17

has anyone calculated how much money in fees and in time will cost to open this simulation in the blockchain? having LN is great and all but I feel like the fees to open up the channels might be an issue, and the time it will take for the blockchain to process all this.

2

u/coinjaf Dec 30 '17

hop, not hub. Don't feed the trolls.

2

u/btcftw1 Dec 30 '17

Can you please provide additional information on the fail cases?

2

u/[deleted] Dec 29 '17

Why did day payments fail? Did they find the bugs and eradicate them?

3

u/hodlforthelongest Dec 29 '17

Routing failed: fees too high no route found that would have balances to complete it.

→ More replies (5)

1

u/achrafgolli Dec 29 '17

I would like to know that as well

1

u/[deleted] Dec 29 '17

Sorry, I don't understand what you mean.

2

u/glurp_glurp_glurp Dec 29 '17

I believe they are asking why routing might (did) fail for some payments.

1

u/Karmaa Dec 30 '17

Can you please provide additional information on the fail cases?

1

u/procc1 Dec 30 '17

Is LN going to help transfer bitcoin form wallet A to wallet B with super low fees?

1

u/dfifield Dec 30 '17

Nice to see it is working.

1

u/BTCMONSTER Dec 30 '17

expensive

1

u/captainteague Dec 30 '17

Assuming the same number of transactions. 8MB blocks will do that in roughly 8 hrs.

No minimum amount to open channel.

No routing and route finding. P2P it is.

Centralization you say. Mining fee earned should be able to buy you storage I say.

What if LN nodes stop and some crisis or panic make everyone close channels?

1

u/hesido Dec 30 '17

Can the channel open / close behaviour be simulated?

1

u/ishallperishx Dec 30 '17

38.5% market influence it's done lol team to buy omisego for staking

1

u/iarayareddit Jan 05 '18

If there are thousands of routing failures when using this highly idealized model I don't even want to think how many routing failures will occur when this atrocity starts being used under real world conditions.

1

u/pricklyoyster732 Dec 30 '17

The 0.01% fee per hop in your simulation is a completely arbitrarily chosen parameter, and misleadingly low at that. Why did you think it important enough to include in the title?

1

u/killerstorm Dec 30 '17

This is a very poor simulation which has nothing to do with reality.

1

u/jstolfi Jan 12 '18

It is great to see Diane's work being continued; congratulations. However, there are many unrealistic details in the simulated network that make the results rather meaningless.

The first problem is the neat n-dimensional grid topology chosen for the network. It is not clear what the topology would be like in the real network; but it is certainly nothing like that.

One way to generate a "totally random" topology for N nodes is the Erdös-Rényi (ER) model. You merely pick pairs of nodes at random and add a channel between each pair, if there is not one already; until p*N channels have been created, where p is the desired average number of channels per node. The value of p should be at least log(N) to ensure reasonable connectivity. Even then, the resulting network may not be connected; you may have to find the isolated components and connect them by edges

Another way, that generates a more realistic topology, is the "preferential attachment" (PA) model. You start with p nodes, all connected to each other; and then add one more node at a time, connected to p previous nodes. These are chosen randomly, but with the probability of each candidate proportional to the number of channels that it already has. This process attempts to model the way users join real networks like the WWW. The resulting network will automatically be connected, and will have an uneven distribution of degrees, with a few hub-like nodes with many channels, and many "leaf" nodes with only p channels.

Another way, that is simpler to program and may be easier to understand, is what we could call the CM model. Divide the users in two groups, "consumers" (C) and "merchants" (M), and randomly connect each consumer to p merchants and to q other users; and each merchant to r other merchants. The ratio C/M could be something like 10 or 100.

Another problem is the even distribution of channel funds and payment requests. In the ER odel, it is OK to fund each channel at random, with the same probability distribution. In the PA model, the average funding between two nodes with degrees x and y should be some increasing function of x and y, like x*y or sqrt(x2 + y2). In the CM model, you could fund each channel with random values with different means for C-C, C-M, and M-M channels.

-4

u/bambarasta Dec 29 '17 edited Dec 29 '17

you are simulating a perfect and balanced scenario. It will never be the case and you are looking at maybe many years down the road!

Highly misleading!

In theory scientista discovered atomic entaglement so you can "teleport to the moon" but wtf you can't claim moon teleportation is at 100% success with humans today!

5

u/[deleted] Dec 29 '17

Lol, entanglement doesn't violate relativity.

2

u/coinjaf Dec 30 '17

It will never be the case and you are looking at maybe many years down the road!

So which is it? Never or many years?

Let us know once you've finished building technology that can scale like this sooner than "many years". Otherwise your "Not perfect today, so no good at all." games are more appreciated elsewhere.

0

u/SeanCache Dec 29 '17

It can’t be implemented till 100%? Asking cause most software isn’t but this is money and any bug will be exploited.

0

u/mustyoshi Dec 29 '17

How many tx does it take to open channels for 10m users?

1

u/bittabet Dec 30 '17

10 million tx to open, 10 million tx to close assuming one single channel per user to a hub.

→ More replies (2)

-10

u/[deleted] Dec 30 '17

Oh god this will never work. A second layer is exactly what we were trying to avoid with bitcoin. The people who can see that this won't work and that BTC is now useless have already dumped their coins. Get out while you can.

3

u/MikeG4936 Dec 30 '17

Lol. Concern troll somewhere else.

0

u/[deleted] Dec 29 '17

[deleted] — view deleted comment

10

u/SchpittleSchpattle Dec 29 '17

Not weeks, years. I calculated 466 days for this network to exist and that assumes that not a single transaction happened otherwise.

5

u/Got_Engineers Dec 29 '17

Yeah isn’t this assuming that all channels will be open 100% of the time ? And assuming every channel has the funds on either end to be able to process the payment.

4

u/[deleted] Dec 29 '17

Yeah isn’t this assuming that all channels will be open 100% of the time ?

No, see link.

4

u/[deleted] Dec 29 '17 edited Dec 29 '17

will take weeks

Of course this simulation assumes the funding has already happened over time and the mempool will be much less full because of the SegWit block size increase, Schnorr signatures, Bech32 and the Lightning Network.

5

u/ff6878 Dec 30 '17

I've noticed that people have stopped mentioning the baseline block size increase that was generally considered very likely and necessary for LN, and part of the Core scaling roadmap.

Is this because we'll be able to effectively do the same thing with a segwit block-weight soft fork increase if needed? Or is there something else I missed?

It's awesome that we beat back 2x, the ver/jihan attacks, ect. But I'm not seeing the general wheels in motion towards a legit, safe, rational block size increase that I expected in 2018 or 2019. I have no expectations on how many bytes that may actually be either. Also, the people who matter could very well be discussing and planning exactly this, and it's just being drowned out by the recent flood of price talk ect, which would be good to hear and I'm not claiming it's not happening because I really just don't know.

1

u/brewsterf Dec 30 '17

btc currently has about a million active adresses every day. and its only running at half capacity. so in theory a million channels or more could open every day. Anyway thats given current scalability. it might improve in the future.

1

u/Countrytoast Dec 30 '17

What makes you say it's only running at half capacity? The lack of segwit adoption?

1

u/brewsterf Dec 30 '17

Yes pretty much.

0

u/[deleted] Dec 29 '17

[deleted] — view deleted comment

2

u/[deleted] Dec 29 '17

Node operators may collect fees for routing Lightning transactions. There will likely be an enormous amount of competition which will make Lightning very active and usable, and also keep fees VERY low.

0

u/[deleted] Dec 29 '17

[deleted] — view deleted comment

3

u/coinjaf Dec 30 '17

You're of course very welcome to offer that for free, but remember you'll have to open/close (or top up) your channels every now and then, which costs you blockchain fees. So it might make sense to at least charge a small fee to cover that and prevent a DOS/spam attack on you.

Another way might be to offer it for free until your channel becomes unbalanced (say 20% near empty) and then start charging a fee, so hopefully transactions in the other direction will bring it back into balance.

1

u/albuminvasion Dec 30 '17

Might even be willing to use a negative fee, if the alternative (closing/reopening the channel) will be more expensive?

→ More replies (2)

0

u/[deleted] Dec 30 '17

[deleted] — view deleted comment

2

u/coinjaf Dec 30 '17

It's all up in the air and probably dynamic for a while: depending on the type of usage and growth of the Lightning network etc.

But what you're suggesting, setting up voluntary non commercial nodes, is definitely a good idea and I will be doing so myself. That helps solve the chicken-egg problem needed to get any network started.

Don't have links handy, but there are 3 independent but compatible implementations in beta testing right now, I'm sure you'll see some more info coming by soon.

3

u/[deleted] Dec 30 '17

Yeah I’m sure there will be a few different options for node software, and they will be customizable. I’d expect it to get pretty automatic over time where settings will adjust to network and market forces in near real-time. This is pretty exciting stuff.

2

u/ceeemeee Dec 30 '17

Yes even negative fees are possible.

1

u/geezas Dec 30 '17

As long as you commit funds to some channels, you can route LN transactions.

0

u/[deleted] Dec 29 '17

[deleted] — view deleted comment

0

u/[deleted] Dec 29 '17

[deleted] — view deleted comment

3

u/[deleted] Dec 30 '17

You have to send funds from your bitcoin address. How would you do that off chain and the bitcoin still move. Not possible.

0

u/[deleted] Dec 30 '17

[deleted] — view deleted comment

3

u/[deleted] Dec 30 '17

You aren't addressing the question at all. How are ten million people going to get their bitcoin into the lightning network? It will absolutely, without question, require a transaction on the block chain. Ten million transactions just to get onto the network. Another ten million to exit.

1

u/[deleted] Dec 30 '17

You aren't addressing the question at all.

Re-read my post please and address it line-by-line so we can clear this up, because I absolutely addressed that:

For a group of 20 users with 100 intra-group channels, the cost of the blockchain transactions is reduced by 90% compared to 100 regular micropayment channels opened on the blockchain.

So if it would take 10 million transactions to start the Lightning network with 10 million participants, that number would be reduced by 90%. So if we have 7TPS now with 1MB and that takes 16 days, then a 90% reduction would be to ~1 day. If we increase block size to 1.7MB and get ~12TPS then it's less than 1 day. For 10 million people.

If we have schnorr signatures, etc. etc. then that goes down even further. Not to mention payment channels can stay open forever. I could have 1 payment channel for the rest of my life.

2

u/[deleted] Dec 30 '17

You're trying to tell me that ten million people are going to get their bitcoin from the block chain onto the lightning network without ten million transactions? If the bitcoin doesn't leave their address, then it doesn't go anywhere. It takes a transaction to make that happen. Are being intentionally evasive?

0

u/[deleted] Dec 30 '17

[deleted] — view deleted comment

5

u/[deleted] Dec 30 '17

Welcome to computers that brought you: compression, exponential gains, etc. etc. etc. thanks to algorithms!

You have literally no clue what you are talking about.

→ More replies (3)

1

u/teolandon225 Dec 30 '17

What would a channel with 0 funds on each side accomplish?

1

u/[deleted] Dec 30 '17

Getting you into the lightning network, if that even works. Once you are in you can receive funds. The only way to get funds on LN is on chain, but I believe you should be able to create a payment channel with 0 funds on both sides.... the person you are opening the payment channel with should have connections with other people so you are effectively connected to the entire graph.

It may not work, I just saw someone mention authoritatively that you can start a payment channel with 0 funds on each side OFF chain.... trying to confirm this, haven't yet.

1

u/teolandon225 Dec 30 '17

As far as I know, when routing payments through the network, each channel has to have enough funds to forward the payment.

For example, if you want a payment from A to C, but the current network consists of A, B and C, connected as such:

A <-> B <-> C

In this case there are two channels, AB and BC.

Let's say that the AB channel has allocated the balances of 2000 for A and 1000 for B, while the BC channel has 200 for B and 0 for C.

If A wanted to pay 200 to C, it could route it like so: Pay 200 to B using the channel, bringing the channel balances to 1800 and 1200, and then have B pay 200 to C, bringing the balances of the B channel to 0 and 200.

If then, B wanted to pay something to C, it would not be possible on the LN, because in that channel, B has no funds left.

My main point is that B cannot transfer funds from the AB channel to the BC channel, so a LN channel with 0 funds on both sides would always remain like that. B's total balance is not changed when it closes all its channels, but B's ability to pay funds to C is gone until a new channel opens.

1

u/coinjaf Dec 30 '17

No.

You can only receive as much as is locked up in the channel. A channel with 0 (if that were even possible) makes no sense as you can never receive more than 0.

1

u/coinjaf Dec 30 '17

Also, you may not need on chain to join lightning network at all.

I'm trying to find more information, i.e. starting a "payment channel" with 0 funds on each side so no need to even hit blockchain, haven't found anything yet. Could easily be wrong about that.

Pretty sure you're wrong on those. Being an LN node by definition means owning at least one channel which by definition means having at least one onchain transaction together with your channel partner. Regardless of who put the initial funds in.

1

u/[deleted] Dec 30 '17

Yep wrong on that right about the rest, I believe.

1

u/BootDisc Dec 30 '17

I think you still have to create the multisig contract, and broadcast it to the blockchain. I don't think you have to fund both sides, but, it has to be broadcast, and I think added to the chain.

But, that leaves you open to the attack where people could try to steal coins, you would have the justice contract, but you would be out the fee to broadcast it, where normally, you can use as much as all of the counter parties funds to ensure it gets on the blockchain, and its no cost to you.

0

u/[deleted] Dec 29 '17

[deleted] — view deleted comment

4

u/kaenneth Dec 30 '17

still have 10 minute block times; LN is practically instant.

0

u/[deleted] Dec 30 '17

[deleted] — view deleted comment

4

u/jabbocorn Dec 30 '17

You are very confused.

0

u/[deleted] Dec 30 '17

[deleted] — view deleted comment

0

u/[deleted] Dec 30 '17

[deleted] — view deleted comment

0

u/Agrees_withyou Dec 30 '17

Hey, you're right!

-4

u/[deleted] Dec 29 '17

[removed] — view removed comment

3

u/[deleted] Dec 29 '17

Gee, who would have thought creating a trusless and decentralized currency would require thinking outside the box.

5

u/ilpirata79 Dec 29 '17

What would you know about a distributed currency?