Mining Calculator

Discussion in 'Proof-of-work Mining' started by avirdoz, Feb 12, 2016.

Tags:
  1. 2017/12/15 - Decred v1.1.2 released! → Release Notes  → Downloads
  1. avirdoz

    avirdoz New Member

    Feb 5, 2016
    14
    2
    Male
    Hello:)
    Is there any mining calculator for decred mining algo?
     
  2. eshriek

    eshriek New Member

    Jan 16, 2016
    45
    12
    Male
    I did see someone post pseudo code on this forum but I cannot seem to find it. It was pretty basic. Looked easy to put into js which I'll try to do if I find it.

    Are you running cgminer now?

    From what I have heard, if you solo mine you will need your "best share" to be above the "diff" to find a block.
    I'm pool mining with about 500Mh/s which is getting under 1 Decred per day (could be closer to .5 Decred). That is consistent with what I've read on the forum.​

    Or are you thinking of buying mining equipment?
     
  3. Reynold

    Reynold Member

    Jan 28, 2016
    198
    70
    Male
    Programmer
    Would like to see an estimate of mining time to find a block solo at X MH/s = hrs or days
     
  4. LastNinja

    LastNinja Full Member

    Dec 31, 2015
    451
    199
    Male
    This is not rocket science. If the global hashrate finds a block every 5 min, how long does it take to find a block for you if you have x percent of the global hashrate. That's it.
     
    ClokworkGremlin likes this.
  5. Reynold

    Reynold Member

    Jan 28, 2016
    198
    70
    Male
    Programmer
    @LastNinja
    Code:
    getmininginfo
    {
      "blocks": 6056,
      "currentblocksize": 3473,
      "currentblocktx": 2,
      "difficulty": 267765.08515919,
      "stakedifficulty": 482237265,
      "errors": "",
      "generate": false,
      "genproclimit": 1,
      "hashespersec": 0,
      "networkhashps": 3976905884572,
      "pooledtx": 12,
      "testnet": false
    }
    
    So based on this block height:
    Code:
    networkhashps: n = 3976905884572
    Seconds to find block (5 min avg): s = 300
    My Hashes/sec: h = 375000
    ----
    (n/h) * s
    
    This means, I will find a block solo mining in
    3,181,524,707.66 seconds
    or
    100.89 years

    Please check my math or logic.

    Thank you.
     
  6. diegox104

    diegox104 New Member

    Jan 4, 2016
    11
    5
    Male
  7. LastNinja

    LastNinja Full Member

    Dec 31, 2015
    451
    199
    Male
    If you own all the hashrate you will find a block every 5min. If you own half the hashrate you will find a block every 10min (every second block). And so on. I don't think there is code needed to figure this out ;)

    With one percent of the total hashrate you will find every 100th block. Just calculate how many percent of the global hashrate you own. Or in other words, with one percent of the global hashrate you will mine one percent of the total PoW rewards on any day/week/month.

    On average!
     
  8. LastNinja

    LastNinja Full Member

    Dec 31, 2015
    451
    199
    Male
    Your hashrate is 375kH/s??? That's not possible. Even your mobile phone would hash faster than that.

    A decent old GPU gives 1GH/s. If network is at 4,000 GH/s it will find one block every 4,000 blocks. That's one block every 14 days on average.
     
  9. Reynold

    Reynold Member

    Jan 28, 2016
    198
    70
    Male
    Programmer
    CGminer shows:
    GPU 0: | 378.1M/372.1Mh/s | A:404 R:1 HW:0 WU:0.0/m I: 6
    ----
    SuprNova shows:
    415,180.17
    ----
     
  10. LastNinja

    LastNinja Full Member

    Dec 31, 2015
    451
    199
    Male
    #10 LastNinja, Feb 28, 2016
    Last edited: Feb 28, 2016
    So why did you use 375kH/s in your above calculation? It's appr. 375MH/s.

    EDIT: Let's make that a whopping 400MH/s or 0.4GH/s. With the network at 4,000GH/s you will find one in 10,000 blocks or one block every 35 days on average. I wouldn't solo mine with this because if you are lucky just on your block the voters will sleep. Better go for a few atoms each block and join a pool. You will on average earn the same.
     
    Reynold likes this.
  11. LastNinja

    LastNinja Full Member

    Dec 31, 2015
    451
    199
    Male
    Yes, it's called back-of-the-envelope calculator and is powered by the Rule of Three ;)
     
    decredited and Reynold like this.
  12. Reynold

    Reynold Member

    Jan 28, 2016
    198
    70
    Male
    Programmer
    I got confused, so SuprNova is showing kh/s, so new calculation is:
    ----
    networkhashps: n = 3976905884572
    Seconds to find block (5 min avg): s = 300
    My Hashes/sec: h = 375000000

    (n/h) * s
    ----
    3,181,524.71 seconds
    or
    36.82 days

    At my speed to find a block mining solo?
    ----
     
  13. Reynold

    Reynold Member

    Jan 28, 2016
    198
    70
    Male
    Programmer
    Actually, I am mostly mining DCR on pools :) as well as turning off my GPU mining when I need to use my computer. Remember that I come from the ASIC world and had no GPU's ready for this coin, so all this is experimental, thus my thread which you've helped me with.
     
  14. LastNinja

    LastNinja Full Member

    Dec 31, 2015
    451
    199
    Male
    Yes, but it doesn't matter if you mine with ASIC Bitcoin or with GPU Decred. The simple calculation outlined above is the same. There is nothing needed just the Rule of Three, the total hashrate and your hashrate.
     
  15. Reynold

    Reynold Member

    Jan 28, 2016
    198
    70
    Male
    Programmer
    That was my mistake, was used to seeing GH/s.

    So my final formula is sound now I see as it matches up with yours.
     
    LastNinja likes this.
  16. Shadowlance

    Shadowlance Full Member

    Jan 9, 2016
    220
    155
    Male
    A formula you can use to get the probability of a block per day is: 1 - (1 - P)^N
    Where:
    P is your slice of the network hash rate.
    N is the number of blocks per day.

    Using the example given above:
    P = 375000000/3976905884572 = 0.00009429
    N = 288 (1440 minutes per day, 5 mins per block)
    So the probability of finding a block on a given day is 1 - (1 - 0.00009429) ^ 288 = 0.02679261

    So there's a 2.68% chance of finding a block each day.
    Unfortunately average block solve speeds are not very useful since the spread around that average is very large.
     
    jmine and Reynold like this.
  17. jmine

    jmine New Member

    Mar 15, 2016
    1
    0
    Male
    1000000000/4608970434653 is my 1 Gh's 1000,000,000 hashes? :)
    1 - (1 - 0.00021696819) ^ 288 = 0.06058094233
    Hello everyone, Decred is the first coin I've ever mined, i couldn't get solo mining working before and tried mining on Coinmine, I was getting 1.4 - 1.7 decred per day with the pool. Now I've managed to set up pool mining since nearly 24 hours, by the formula it seems if I've used it correctly I should have 6% chance. Is it worth me solo mining or should get back to pool mining? :) I think it's working propely, at least I am connected now :)

    Thank you all, it's been so much fun getting this all set up :) Not sure if anything is wrong here in my dcrd, I have had this message twice today:

    dcrd
    12:15:31 2016-03-15 [INF] BMGR: Processed 1 block in the last 2m6.08s (6 transactions, height 10579, 2016-03-15 12:15:34 +0000 GMT)
    12:15:42 2016-03-15 [INF] CHAN: FORK: Block 0000000000003d5bff25ba7b889e129f556f4bd26a8ded048a474876048cbbc0 (height 10580) forks the chain at height 10579/block 0000000000003902577d09e885d4f687c87810f3f18228d5d464cfe89d055aa4, but does not cause a reorganize
    12:15:42 2016-03-15 [INF] BMGR: Processed 2 blocks in the last 10.4s (2 transactions, height 10580, 2016-03-15 12:15:47 +0000 GMT)


    cgminer
    cgminer version 3.7.2 - Started: [2016-03-15 18:27:47]
    --------------------------------------------------------------------------------
    (5s):1.053G (avg):1.059Gh/s | A:0 R:0 HW:0 WU:14.9/m
    ST: 3 SS: 0 NB: 84 LW: 0 GF: 5 RF: 0
    Connected to 127.0.0.1 diff 287K without LP as user
    Block: 10769 Diff:287K Started: [02:18:17] Best share: 6.75K
    --------------------------------------------------------------------------------
    [P]ool management [G]PU management ettings [D]isplay options [Q]uit
    GPU 0: | 1.053G/1.059Gh/s | A:0 R:0 HW:0 WU: 14.9/m I: 7
    --------------------------------------------------------------------------------

    [2016-03-16 00:25:14] New block detected on network
    [2016-03-16 00:31:11] New block detected on network
    [2016-03-16 00:41:06] New block detected on network

    dcrwallet
    01:06:35 2016-03-16 [INF] WLLT: Connecting block 00000000000035205d08f6280a63a2f952f922e63b71938e544266a45cdbd4a3, height 10755
    01:09:17 2016-03-16 [INF] WLLT: Connecting block 0000000000000ffa143cee347e1214bafc0135fb33231a11ecdd863307caf21d, height 10756
     
  18. Shadowlance

    Shadowlance Full Member

    Jan 9, 2016
    220
    155
    Male
    First of all, don't worry about the forking. I'm not exactly sure what it is, but it is normal behaviour that happens in the chain from time to time.

    Second, your math is correct, you have about a 6% chance of mining a block per day. Another way of looking at it is by using N = 288 * 30 which is the approximate number of blocks in a month. In this case there is an 84.67% chance of finding a block each month. The current payout for a block is 18.532 DCR, thus over time your income from PoW will approach 15.691 DCR/month or 0.532 DCR/day. Keep in mind though, that the total hash rate of the network can fluctuate wildly (right now it's 3.4 TH/s which is around 25% less than what your numbers are) so this number will not be accurate. You'd need more data on the average network hash rate over time to get close to the real number.

    In the end, it's up to you if it's worth it. If you want to see frequent gains, you'd best go back to pool mining since you'll solve less than one block a month solo mining. If you don't mind waiting for your payment then go ahead and solo mine. The question is does it cover your electricity expenses and if not, does that matter to you?

    Mathematically, it shouldn't matter what you choose. The payout should be more or less the same over long time periods. The difference is that instead of getting paid by the proportion of network hash you have, you get paid by the proportion of pool hash. The pool, however, still gets paid by proportion of network hash so you end up with smaller, more frequent payouts as opposed to rarer, larger payments. Note this does not take into account pool fees. It's the Commutitive Law in action: (A x B) x C = A x (B x C)
     
  19. Serg

    Serg New Member

    Jan 28, 2016
    5
    6
    Male
    zero, evanjdevs, Reynold and 3 others like this.

Share This Page