Menu

Quick spike-logarithmic test of PRNGs (good at least for local-short PRNG sequences)

2021-08-13
2021-10-07
  • Aleksey Vaneev

    Aleksey Vaneev - 2021-08-13

    I've composed a pretty simple program (in public domain) that quickly finds PRNG bit relationships going spike-logarithmic (or beta distribution with alpha=0.5, beta=1). This is not a meticulously-scientific test, because it needs tuning of "thrs" (threshold) to a reference "true random noise" (not having a theory), and to a block size. I only did the test to gain more self-confidence in PRVHASH. I did group-comparison based on PRNGs from https://github.com/lemire/testingRNG

    On spike-logarithmic (a=0.5,b=1) PDF, I'm attaching image, it's just a product of PRNG by itself. The product of uncorrelated PRNGs is a logarithmic PDF. This spike-logarithmic PDF is very effective in my BiteOpt optimizer for population members selection. But not so great for economy, and may also depict internal problems in PRNGs.

     

    Last edit: Aleksey Vaneev 2021-10-07
  • Aleksey Vaneev

    Aleksey Vaneev - 2021-08-13

    testpdf.cpp

     
  • Aleksey Vaneev

    Aleksey Vaneev - 2021-08-13

    It considers 64-bit continous PRNG stream values, but can be scaled at will - e.g. 8-bit, 16-bit, 128-bit values. There may be problems in PRNG at different scales.

     
  • Aleksey Vaneev

    Aleksey Vaneev - 2021-08-14

    Oh well, things depend on seed values, so checking several seeds is needed. So, I may be wrong about "tendency", as depending on seed various bit pairs pop up. Anyway, an interesting test IMO. Maybe someone can refine it further.

     
  • Aleksey Vaneev

    Aleksey Vaneev - 2021-10-07

    "Spike-logarithmic" is a moniker for beta distribution with alpha=0.5, beta=1. It's not exactly this beta distribution around 0; as beta distribution is infinite at 0, this "spike-logarithmic" diverges there.

     

Log in to post a comment.