Skip to content

a-tokyo/cryptocurrency-simulation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 

Repository files navigation

cryptocurrency-simulation

A cryptocurrency (Bitcoin) Simulation.

What is the main Idea?

In this project, we will design a cryptocurrency similar to BitCoin. We will simulate a multi-user network, once a transaction is made, the user announces it to his near peers. Not all users get notified by the transaction, you can randomize the notification process. Once the user accumulate n transaction, he can form a block by accumulating transactions and doing a computationally expensive task (e.g. finding a nonce that hasn’t be used in the ledger before) and append this nonce to the block. Once the block is formed, it can now be announced. After a block announcement, users who are notified about this block, will add it to their version of the ledger and the majority of them have to consent that this version of the ledger is the same version they have. Users with different version than this version will have to throw away their versions and adopt this one.

Deliverables

  • A transaction will be treated as a black box with a transaction ID.
  • A simulation of the network, with multiple users and the randomized process of announcing a transaction, making each transaction reach an arbitrary set of users.
  • The design and implementation of the ledger based on the concept of the blockchain (hash linked list)
  • The puzzle needed to announce the block, you can find a computationally expensive task that’s used in famous blockchains and apply it in your system.
  • The process of building a block out of a set of transactions, a hash to the preceding block and a nonce generated by the computationally expensive task.
  • The process of announcing the block to an arbitrary set of users.
  • Having the users consent that once they received the announced block, their ledger (blockchain) align with that of the other users. And having users with different versions of the ledger adopt the consented version instead.