Bitcoin Forum
December 16, 2019, 01:34:46 PM *
News: Latest Bitcoin Core release: 0.19.0.1 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 2 [3]  All
  Print  
Author Topic: How random the last digit of a block hash really is?  (Read 23390 times)
RocketSingh
Legendary
*
Offline Offline

Activity: 1624
Merit: 1032


View Profile
November 24, 2016, 04:51:54 PM
 #41

16 times is too much , that means they didn't make money from it .
Too much! LoLz... nothing is too much in gambling, as long as it is balanced with odds, which is pretty much the case here.

And I think people will rarelly play a game with 1/16 chance to win.
Gamblers are not so dumb that they'll place a bet on a single option. By betting on multiple options in a single block, they'll increase their chance of win.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1576503286
Hero Member
*
Offline Offline

Posts: 1576503286

View Profile Personal Message (Offline)

Ignore
1576503286
Reply with quote  #2

1576503286
Report to moderator
Viceroy
Hero Member
*****
Offline Offline

Activity: 896
Merit: 501



View Profile
November 26, 2016, 09:32:05 PM
 #42

100% random, and most betting sites use this as their system for fair, verifiable game play.

.Minter.                       ▄▄▄▄▄▄▄▄▄
                  ▄▄▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▄▄
               ▄▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▄
            ,▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▄
          ,▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▄
         ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
        ▓▓▓▓▓▓▓▓▓▓█▀█▓▓▓▓▓▓▓▓▓▓▓▓▓▓▀█▓▓▓▓▓▓▓▓▓▓
       ▓▓▓▓▓▓▓▓▓▓▓    █▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓
      █▓▓▓▓▓▓▓▓▓▓▓▓▓    ▀▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓
      ▓▓▓▓▓▓▓▓▓▓▓▓▓█▓▓▄   ▀▓▀   ▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓
     ▐▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▄     ▄▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▌
     ╟▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▄ ▄▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▌
     ▐▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▌
      ▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓
      ║▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▌
       ▀▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓▓▓   ▓▓▓▓▓▓▓▓▓▓▓
        ▀▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
         ╙▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▀
           ▀▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▀
             ▀█▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▀
                ▀█▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓█▀
                     ▀▀██▓▓▓▓▓▓▓██▀▀
||

╓▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒
▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓█▀▀▀▀▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓         ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓▓▓         ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓▓▌        ▐▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓▓         ▀╜        ╙▀▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓▓                      ▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓▌                       ▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓                        ▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓         ▓▓▓▓▓▌         ▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▌         ▓▓▓▓▓          ▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓⌐         ▓▓▓▓▓         ╣▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓         ▀█▀▀^         ╫▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▌                      ▒▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓                     ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓                 #▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▌
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▌
▀▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
 ▀▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▀
 ╙▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▀
WALLET




                   ▄▄████
              ▄▄████████▌
         ▄▄█████████▀███
    ▄▄██████████▀▀ ▄███▌
▄████████████▀▀  ▄█████
▀▀▀███████▀   ▄███████▌
      ██    ▄█████████
       █  ▄██████████▌
       █  ███████████
       █ ██▀ ▀██████▌
       ██▀     ▀████
                 ▀█
arulbero
Legendary
*
Offline Offline

Activity: 1303
Merit: 1372


View Profile
December 07, 2016, 12:40:34 PM
 #43

I have checked the last digit distribution of every block hash (16 possible values and 442034 blocks):

Code:
BLOCKS : from 0 to 442033 (TOT = 442034)
last
digit         fr.         prob.           unif. -->  1/16=0.0625
0           27520   0.0622576543886                    
1           27881   0.0630743336485
2           27952   0.0632349547772       MAX -->  =+0.00073495777 = +1,16%
3           27892   0.0630992186121
4           27543   0.0623096865852
5           27339   0.0618481836239
6           27674   0.062606043879
7           27691   0.0626445024591
8           27428   0.0620495256021
9           27203   0.061540514983        MIN --> -0.000959485 = -1.54%
10 (a)      27594   0.0624250623255
11 (b)      27554   0.0623345715488
12 (c)      27863   0.063033612799
13 (d)      27616   0.0624748322527
14 (e)      27619   0.062481619061
15 (f)      27665   0.0625856834542

I think it's ok.

Syke
Legendary
*
Offline Offline

Activity: 3164
Merit: 1039


View Profile
December 09, 2016, 06:14:28 PM
 #44

I have checked the last digit distribution of every block hash (16 possible values and 442034 blocks):

Code:
BLOCKS : from 0 to 442033 (TOT = 442034)
last
digit         fr.         prob.           unif. -->  1/16=0.0625
0           27520   0.0622576543886                    
1           27881   0.0630743336485
2           27952   0.0632349547772       MAX -->  =+0.00073495777 = +1,16%
3           27892   0.0630992186121
4           27543   0.0623096865852
5           27339   0.0618481836239
6           27674   0.062606043879
7           27691   0.0626445024591
8           27428   0.0620495256021
9           27203   0.061540514983        MIN --> -0.000959485 = -1.54%
10 (a)      27594   0.0624250623255
11 (b)      27554   0.0623345715488
12 (c)      27863   0.063033612799
13 (d)      27616   0.0624748322527
14 (e)      27619   0.062481619061
15 (f)      27665   0.0625856834542

I think it's ok.

It's not enough to check the frequency. For instance, the sequence "1 2 3 1 2 3 1 2 3" has equal frequencies, but is unlikely to be random.

Buy & Hold
cpfreeplz
Legendary
*
Offline Offline

Activity: 966
Merit: 1036


View Profile
December 09, 2016, 06:27:08 PM
 #45

It's not enough to check the frequency. For instance, the sequence "1 2 3 1 2 3 1 2 3" has equal frequencies, but is unlikely to be random.

If you tried with a few thousand blocks this wouldn't show a more scientific answer rather than "I rolled a die 6x and I got 3 twice, therefore the odds of rolling a 3 on a die is 1 in 3" . It's just not how odds work.
dreamhouse
Hero Member
*****
Offline Offline

Activity: 1072
Merit: 666



View Profile
December 10, 2016, 12:20:40 AM
 #46

Last digit of block hash should be close to true random. I remember seeing some altcoins generate random blocks using some fixed bits in hash (usually a letter in the middle), and some dev did stats and showed the randomness is almost perfect.

           ▀██▄ ▄██▀
            ▐█████▌
           ▄███▀███▄
         ▄████▄  ▀███▄
       ▄███▀ ▀██▄  ▀███▄
     ▄███▀  ▄█████▄  ▀███▄
   ▄███▀  ▄███▀ ▀███▄  ▀███▄
  ███▀  ▄████▌   ▐████▄  ▀███
 ███   ██▀  ██▄ ▄██  ▀██   ███
███   ███  ███   ███  ███   ███
███   ███   ███████   ███   ███
 ███   ███▄▄       ▄▄███   ███
  ███▄   ▀▀█████████▀▀   ▄███
   ▀████▄▄           ▄▄████▀
      ▀▀███████████████▀▀
DeepOnion      ▄▄██████████▄▄
    ▄███▀▀      ▀▀█▀   ▄▄
   ███▀              ▄███
  ███              ▄███▀   ▄▄
 ███▌  ▄▄▄▄      ▄███▀   ▄███
▐███  ██████   ▄███▀   ▄███▀
███▌ ███  ███▄███▀   ▄███▀
███▌ ███   ████▀   ▄███▀
███▌  ███   █▀   ▄███▀  ███
▐███   ███     ▄███▀   ███
 ███▌   ███  ▄███▀     ███
  ███    ██████▀      ███
   ███▄             ▄███
    ▀███▄▄       ▄▄███▀
      ▀▀███████████▀▀
.....DeepVault.....
....Blockchain File Signatures....
...deeponion.org...
valley365
Hero Member
*****
Offline Offline

Activity: 896
Merit: 1003


View Profile
December 12, 2016, 09:31:22 AM
 #47

Last digit of block hash should be close to true random. I remember seeing some altcoins generate random blocks using some fixed bits in hash (usually a letter in the middle), and some dev did stats and showed the randomness is almost perfect.

yes I remember some coins like Jackpotcoin did tests on it, you can check its thread for more detailed info.
CounterEntropy
Full Member
***
Offline Offline

Activity: 176
Merit: 181


View Profile
December 14, 2016, 09:48:57 PM
 #48

100% random, and most betting sites use this as their system for fair, verifiable game play.
May I know, apart from Chain-Bet.com, who else is using this?
cloverme
Legendary
*
Offline Offline

Activity: 1498
Merit: 1041


SpacePirate.io


View Profile WWW
December 14, 2016, 10:36:50 PM
 #49

I'm using it for some elements in my game. For example, the last number in the hash might correlate to the number of asteroids in a sector of space  Grin
Bitcoin Gambling
Member
**
Offline Offline

Activity: 137
Merit: 10


View Profile WWW
February 13, 2017, 11:24:23 AM
 #50

I'm using it for some elements in my game. For example, the last number in the hash might correlate to the number of asteroids in a sector of space  Grin

Nice to see more use cases of the last digit of bitcoin block hash. Smiley

arulbero
Legendary
*
Offline Offline

Activity: 1303
Merit: 1372


View Profile
April 07, 2017, 12:56:22 PM
 #51

New question:

If I generate 2^ 160 distinct points (in secp256k1), then I perform sha256 + ripemd160, I could get 2^160 different values (and then all the possible addresses)?

A point (x,y) is a 512 bit string  -> "04xy" -> sha256 + ripemd160

My guess is: if I generate 2^160 points is like if I generated 2^160 pseudo-random 512 bit strings, so there should be many repetitions.

According to "law of third" -> http://www.roulette30.com/2010/04/law-of-third.html

 I should get only 2/3 * 2^160 distinct values, not the entire space. Am I right or not?

And if I generated 2^161, or 2^162 ? What % of distinct addresses (on the total of 2^160 addresses) I will get?

HI-TEC99
Legendary
*
Offline Offline

Activity: 1722
Merit: 1096



View Profile
April 08, 2017, 06:07:45 PM
Last edit: April 08, 2017, 06:19:30 PM by HI-TEC99
 #52

It's not enough to check the frequency. For instance, the sequence "1 2 3 1 2 3 1 2 3" has equal frequencies, but is unlikely to be random.

If you tried with a few thousand blocks this wouldn't show a more scientific answer rather than "I rolled a die 6x and I got 3 twice, therefore the odds of rolling a 3 on a die is 1 in 3" . It's just not how odds work.

+1

There's official government backed standards for testing randomness, and testing software called the NIST Statistical Test Suite software. However, even the official government standards say "statistical testing cannot serve as a substitute for cryptanalysis". Statistical testing by itself isn't enough, and good statistical testing can require 10^18 or more random numbers to test.

The details of the testing software are in this quote from another thread.


NIST produced some software for conducting statistical testing on data produced by random number generators. However it requires compiling, and needs huge data sets to work with.

http://csrc.nist.gov/groups/ST/toolkit/rng/documents/SP800-22rev1a.pdf

Quote
This paper discusses some aspects of selecting and testing random and pseudorandom number generators.The outputs of such generators may be used in many cryptographic applications, such as the generation of key material. Generators suitable for use in cryptographic applications may need to meet stronger requirements than for other applications. In particular, their outputs must be unpredictable in the absence of knowledge of the inputs. Some criteria for characterizing  and selecting appropriate generators are discussed in this document. The subject of statistical testing and its relation to cryptanalysis is also discussed, and some recommended statistical tests are provided. These tests may be useful as a first step in determining whether or not a generator is suitable for a particular cryptographic application. However,no set of statistical tests can absolutely certify a generator as appropriate for usage in a particular application, i.e., statistical testing cannot serve as a substitute for cryptanalysis

This is the download link for the the NIST Statistical Test Suite software.

http://csrc.nist.gov/groups/ST/toolkit/rng/documentation_software.html


Testing if a sequence of numbers is random is incredibly difficult, as random.org points out.

https://www.random.org/analysis/

Quote
If you flip enough coins, you will get sequences of coin flips that seen in isolation from the rest of the sequence don't look random at all. Scott Adams has drawn this as a Dilbert strip, which is funny exactly because it is true:



What Dilbert is told is correct: It is impossible to prove definitively whether a given sequence of numbers (and the generator that produced it) is random. It could happen that the creature in the comic strip has been generating perfectly random numbers for many years and that Dilbert simply happens to walk in at the moment when there's six nines in a row. It's not very likely, but if the creature sits there for long enough (and Dilbert visits enough times), then it will eventually happen.


There is more software for testing randomness called dieharder. It doesn't run all the NIST tests yet, but earlier software it's based on (called diehard) required a default input to work on of ten million random numbers in a file. Dieharder requires much more data than that to run sensitive tests.



http://www.phy.duke.edu/~rgb/General/dieharder.php

Quote
Dieharder differs significantly from diehard in many ways. For example, diehard uses file based sources of random numbers exclusively and by default works with only roughly ten million random numbers in such a file. However, modern random number generators in a typical simulation application can easily need to generate 10^18 or more random numbers, generated from hundreds, thousands, millions of different seeds in independent (parallelized) simulation threads, as the application runs over a period of months to years. Those applications can easily be sensitive to rng weaknesses that might not be revealed by sequences as short as 10^7 uints in length even with excellent and sensitive tests. One of dieharder's primary design goals was to permit tests to be run on very long sequences.

*snip*

In addition to implementing all of the diehard tests it is expected that dieharder will eventually contain all of the NIST STS and a variety of tests contributed by users


Andre_Goldman
Sr. Member
****
Offline Offline

Activity: 322
Merit: 251

Property1of1OU


View Profile
April 09, 2017, 11:02:18 AM
 #53

Hashes are uniformly distributed over the entire number space, so to answer you question, they are as random as they get. Furthermore, such hashes are routinely used in provably fair algorithms in other sites, sort of like an industry best practice.

I read somewhere in textbooks that computers are bad on random because they're designed to be deterministic machines.

edit: typo

Patent1number: ****-****
cloverme
Legendary
*
Offline Offline

Activity: 1498
Merit: 1041


SpacePirate.io


View Profile WWW
April 09, 2017, 06:17:25 PM
 #54

Here's a good example of an interesting project toward random number generation: https://www.fourmilab.ch/hotbits/

Just remember your radiation suit  Cool
CounterEntropy
Full Member
***
Offline Offline

Activity: 176
Merit: 181


View Profile
October 24, 2017, 06:55:56 PM
 #55

Here's a good example of an interesting project toward random number generation: https://www.fourmilab.ch/hotbits/

Just remember your radiation suit  Cool
Who'd like to expose themselves to radiation for some random number, while there are abundant sources on earth for the same? Cheesy
Dabs
Legendary
*
Online Online

Activity: 2534
Merit: 1333


The Concierge of Crypto


View Profile
October 27, 2017, 12:47:18 PM
 #56

Hmm.. Their house edge is now 6.25% ? 1/16 chance to win 15 times.

Anyone can make money running a site that uses provably fair random numbers, or provably deterministic "random" numbers, based on seeds or block hashes.

The problem is having enough players, so it boils down to marketing, word of mouth, promotions ... I still like to run a site, just can't keep promoting it, so I had to close mine.

Pages: « 1 2 [3]  All
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!