Skip to content

A program for benchmarking and testing pseudo-random generators for use in computer RPGs.

Notifications You must be signed in to change notification settings

pstef/prng-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
1500100900
Dec 14, 2014
3db568e · Dec 14, 2014

History

28 Commits
Apr 13, 2013
Aug 4, 2013
Dec 14, 2014
Jun 1, 2013
Apr 13, 2013
Apr 12, 2013
Apr 12, 2013
Aug 4, 2013
Apr 12, 2013
Apr 12, 2013
Apr 12, 2013
Apr 12, 2013
Apr 12, 2013
Apr 12, 2013
Apr 12, 2013
Apr 19, 2013
Dec 13, 2014

Repository files navigation

prng-test

A program for benchmarking and testing pseudo-random generators for use in computer RPGs.

What's done:

  • I've adapted a few implementations of PRNGs, including Mersenne-Twister, WELL, Xorshift, and Mitchell-Moore
  • the program can produce a stream of pseudo-random numbers, which is handy for testing quality of a PRNG with an external program, such as ent or dieharder.

Currently supported options:

  • h: help
  • l: list all generators and exit
  • g: select one generator
  • b: don't make built-in tests, generate binary instead
  • s: use external seed; -s `date +'%s'` is a nice example
  • n: generate n 32-bit numbers
  • o: output to file instead of stdout

Currently implemented generators:

  • derp - a number generator of extremely poor quality, but fast and, apparently, well distributed
  • LGC-k1 - a fast Linear Congruential Generator as described by George Marsaglia
  • MM - Mitchell-Moore from The Art of Computer Programming by Donald E. Knuth
  • MMopt - A slightly different implementation of Mitchell-Moore
  • MT19937 - Mersenne-Twister
  • MWC256 by George Marsaglia
  • p_rand - some LGC I know from Jon Lambert
  • WELL44497a - Well Equidistributed Long-period Linear, k=44497, no tempering
  • WELL44497b - WELL, k=44497, with tempering
  • WELL512 - WELL, k=512
  • Xorshift-k4 by George Marsaglia
  • Xorshift-k5 by George Marsaglia

References and Links

About

A program for benchmarking and testing pseudo-random generators for use in computer RPGs.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published