Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def filechain():
- blockchainGrowthPerYear = 110 * 1024 * 1024 * 1024 # bytes
- blockTime = 600 # seconds
- hashSize = 224 / 8 # bytes
- blocksPerYear = 365 * 24 * 60 * 60 / blockTime
- blockSize = blockchainGrowthPerYear / blocksPerYear
- dataSize = blockSize / 2 # size of file chunk (blockSize / 2 maximizes motivated storage capacity)
- movieSize = 8 * 1024 * 1024 * 1024 # assume the typical file is a 8GB movie
- nHashes = movieSize / dataSize
- hashPercentage = 0.5 # assume half of blockspace is occupied by money transfer transactions
- nMoviesPerBlock = hashPercentage * (blockSize - dataSize) / (hashSize * nHashes + 72 + 4 + 256) # signature, miner fee, additional info
- yearlyCapacity = nMoviesPerBlock * movieSize * blocksPerYear
- traffic = yearlyCapacity / blocksPerYear / blockTime / 1024 / 1024
- numPoolMachines = 10000 # community pool size
- totalTokenCost = 40000000 # assume that all datachain tokens are valued at 40 mio USD by the market
- rewardPercentage = 0.00000078125 / 2 # blockReward/totalTokenCost, the value is assumed to be roughly equal to bitcoin
- terabyteCostPerYear = 5 # cost of storing 1TB of data per year, in USD
- yearlyCapacityStorageCost = terabyteCostPerYear * yearlyCapacity / 1024 / 1024 / 1024 / 1024
- numMinedBlocksToBreakEven = yearlyCapacityStorageCost / (totalTokenCost * rewardPercentage)
- print "yearly capacity storage cost (USD):", yearlyCapacityStorageCost
- print "hashpower percentage to breakeven on storage (%):", 100.0 * numMinedBlocksToBreakEven / blocksPerYear
- print "movies per block:", nMoviesPerBlock
- print "storage per pool machine (GB):", yearlyCapacity / numPoolMachines / 1024 / 1024 / 1024
- print "traffic per second (MB/s):", traffic
- print "capacity per block (GB)", yearlyCapacity / blocksPerYear / 1024 / 1024 / 1024
- print "block size (MB):", float(blockSize) / 1024 / 1024
- print "yearly capacity (PB):", yearlyCapacity / 1024 / 1024 / 1024 / 1024 / 1024
- print "movies stored per year:", yearlyCapacity / movieSize
- filechain()
Advertisement
Add Comment
Please, Sign In to add comment