public inbox for bitcoindev@googlegroups.com
 help / color / mirror / Atom feed
From: Christophe Biocca <christophe.biocca@gmail•com>
To: bitcoin-development@lists•sourceforge.net
Subject: Re: [Bitcoin-development] Bitcoin Network Simulator
Date: Sun, 17 Nov 2013 22:59:04 -0500	[thread overview]
Message-ID: <CANOOu=9CwTOi37FJXXNjMirN9RhYdF=W21DV0BzKV9HCCksJBg@mail.gmail.com> (raw)
In-Reply-To: <63B3BF21-C487-4D62-8BB8-18C90F2C3F4C@rbrune.de>

[-- Attachment #1: Type: text/plain, Size: 2535 bytes --]

Beat me to it. My own implementation is here:
https://github.com/christophebiocca/bitcoin-network-simulator
Same basic principles, but I've been following the protocol message
structure as much as possible/Theoretical support for transaction
propagation (I really want to see zero-conf stuff, and whether it works).
Running a network of 1000 full nodes (with 100 miners) for a week of
simulated time (with a normal hashrate) and empty blocks (except for the
coinbase transaction) takes about 30-60 seconds.
Uses nodejs, with the ultimate goal of having a network/chain visualization
running in the browser (with the actual simulation running on a WebWorker
to keep things responsive).


On Sun, Nov 17, 2013 at 11:43 AM, Rafael Brune <mail@rbrune•de> wrote:

> Over the last days I spent some time working on a simple Bitcoin network
> simulator.
> It is a stochastic event-based continuous-time simulation of Bitcoin miners
> exchanging messages and building block chains. It simulates latency,
> bandwidth
> and also verification speed but it currently does not simulate
> propagation/inclusion
> of transactions and instead uses random block sizes.
>
> The simulator includes two examples, one for a 51% attack and the other is
> an
> implementation of selfish mining (pretty much 1:1 as described in the
> paper).
> With the random parameters I picked it seems like it pays off to mine
> selfish with
> >=30% of the hashing power - but take this with a huge grain of salt as
> this
> is with a very small network and randomly chosen parameters. And of course
> it
> is not a perfect replica of the real world network.
>
> Since this is based on my understanding of the Bitcoin network and
> protocol it
> would be great if others would take a look and help improve it.
>
> The project can be found on my github:
> https://github.com/rbrune/btcsim
>
> Regards,
>  Rafael Brune
>
> ------------------------------------------------------------------------------
> DreamFactory - Open Source REST & JSON Services for HTML5 & Native Apps
> OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
> Free app hosting. Or install the open source package on any LAMP server.
> Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
> http://pubads.g.doubleclick.net/gampad/clk?id=63469471&iu=/4140/ostg.clktrk
> _______________________________________________
> Bitcoin-development mailing list
> Bitcoin-development@lists•sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bitcoin-development
>

[-- Attachment #2: Type: text/html, Size: 3382 bytes --]

      reply	other threads:[~2013-11-18  3:59 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-17 16:43 Rafael Brune
2013-11-18  3:59 ` Christophe Biocca [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CANOOu=9CwTOi37FJXXNjMirN9RhYdF=W21DV0BzKV9HCCksJBg@mail.gmail.com' \
    --to=christophe.biocca@gmail$(echo .)com \
    --cc=bitcoin-development@lists$(echo .)sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox