{"id":13499394,"url":"https://github.com/gdistasi/LNSim","last_synced_at":"2025-03-29T04:31:18.727Z","repository":{"id":92437832,"uuid":"104233144","full_name":"gdistasi/LNSim","owner":"gdistasi","description":"A simulator for the Lightning Network","archived":false,"fork":false,"pushed_at":"2020-06-25T09:45:07.000Z","size":20115,"stargazers_count":12,"open_issues_count":1,"forks_count":4,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-05-21T20:14:34.280Z","etag":null,"topics":["bitcoin","blockchain-technology","lightning-network","simulation"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gdistasi.png","metadata":{"files":{"readme":"README","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS"}},"created_at":"2017-09-20T15:24:16.000Z","updated_at":"2024-02-23T16:07:21.000Z","dependencies_parsed_at":"2023-03-09T07:15:22.991Z","dependency_job_id":null,"html_url":"https://github.com/gdistasi/LNSim","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gdistasi%2FLNSim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gdistasi%2FLNSim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gdistasi%2FLNSim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gdistasi%2FLNSim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gdistasi","download_url":"https://codeload.github.com/gdistasi/LNSim/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246140565,"owners_count":20729797,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bitcoin","blockchain-technology","lightning-network","simulation"],"created_at":"2024-07-31T22:00:32.720Z","updated_at":"2025-03-29T04:31:13.713Z","avatar_url":"https://github.com/gdistasi.png","language":"C++","funding_links":[],"categories":["Developer Resources"],"sub_categories":["Simulators"],"readme":"LNSIM (Lightning Network SIMulator)\n============================================================================================\n\nIn the following you can find the documentation to run simulations on the LN (Lightning Network) simulator.\nIf you use this software please consider citing [1].\n\nCompilation: make\n\nUsage: LNSim --numNodes X --numSources X --numDestinations X --connectionProbability X ...  \n\nIn the following the description of the different configuration parameters.\n\nTopology specification; a set of parameters to specify how the LN is generated\n    \n    --numNodes X \n    Specifies the numbers of nodes in the network.\n    \n    --numSources X\n    --numDestinations X \n    \n    Specify the number of sources and destinations for the generated payments, picked randomly among the LN nodes (a node can be selected as both sender and destination)\n    \n    --connectionProbability X\n\n    Specifies with wich probability a payment channel is created between each couple of LN nodes\n    \n    Alternatively the topology can be provided on a file. Such file has to have the format as specified in the following: the first line contains the number of nodes. The subsequent lines contain each a payment channel specification, in the following format:\n    \n    node_id_source node_id_destination capacity_source capacity_destination\n    \n    \nInitial channel funds specification:\n\n    --minFunds funds_in_satoshis --maxFunds funds_in_satoshis\n    \n    Channels endpoints' funds will be initially loaded with an amount randomly chosen between minFunds and maxFunds-\n    \n    \nPayment generation:\n    \n    --intervalPayments s --totalTime s --maxPayments N --meanSizePayments 300000000. --variancePayments 120000000\n    \n    This set of parameters specify how the payments are created to test the network. \n    \n    \nFee specification:\n\n    This part specifies how the forwarding nodes apply the fee for forwarding the payment (at the moment is not possible to choose different fee policies for different nodes).\n\n    --baseFee millisatoshi --feerateLow millisatoshis_per_satoshi --feerateHigh millisatoshi_per_satoshi \n    \n    baseFee is the fee appliead for the payment that does not depend on the payment amount\n    feerateLow is the fee (expressed as millisatoshis per satoshi sent) for the part of the payment that helps balancing the channel\n    feerateHigh is the fee (expressed as millisatoshis per satoshi sent) for the part of the payment that increase the imbalance of the channel\n    \n    If feerateLow==feewateHigh the applied fee is simply proportional (plus the base fee)\n    \n    \nRouting algorithm:\n    --paymentMethod [sp|mp] \n    \n    sp stands for singlepath (one path, the one that minimizes the fees, according to the exact algorithm);\n    mp stands for multipath (multiple path, the ones the minimize the fees, according to the algorithm to be chosen with the following parameter)\n    \n    \nResolution Method (for the finding of paths):\n    --resolutionMethod [exact|heuristic]\n    \n    Exact specifies the selection of the exact resolution method. An exact method exists for the singlepath case and the multipath (the multipath case is slow because of the complexity of the algorithm).\n    Heustic specifies, in conjunction with the mp payment method, an heuristic based approach to find the best paths for the single payment.\n    \n    \nSeed:\n    --seed X\n    \n    Seed specification which is used by the random number generators of the simulator.\n\n        \nLog file:\n    --logFile filename\n    \n    The log file contains a series of lines where each line contains a series of measures that are made on the LN over time. Each line fields are the following:\n    \n    \"time amount src dst successes fails acceptRatio averageImbalance averagePathLength averageFee feesPaid minFunds maxFunds\"\n    \n    time: the time the measure was taken\n    Amount: the payment just processed\n    src: the source of the payment just processed\n    dst: the destination \" \"\n    successes: the total number of successful payments since beginning\n    fails: the total number of failed payments since beginning\n    acceptRatio: the ratio of the payments that have been successful since beginning\n    averageImbalance: a measure of the imbalance of the network at that moment (refer to  [1] for an explanation)\n    averagePathLength: the average path length of all successful payments since beginning\n    averageFee: the average fee of successful payments in millisatoshis since beginning\n    feesPais: the total amount of fees feesPaid\n    minFunds: the lowest value for an endpoint balance at time\n    maxFunds: the highest value for an endpoint balance at time\n    \n    \nExample:\n\n./LNSim --numNodes 200 --numSources 200 --numDestinations 200 --connectionProbability 0.031 --minFunds 1000000000 --maxFunds 5000000000 --intervalPayments 0.1 --totalTime 100000 --maxPayments 1000000  --baseFee 1000 --feerateLow 30 --feerateHigh 30  --paymentMethod sp --resolutionMethod exact   --seed 0 --logFile log.txt\n\n\n\n[1] G. Di Stasi, S. Avallone, R. Canonico, G. Ventre. Routing payments on the lightning network. In proceedings of the 2018 International Conference on Blockchain (Blockchain-2018)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgdistasi%2FLNSim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgdistasi%2FLNSim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgdistasi%2FLNSim/lists"}