Skip to main content

Random Number Generators with Period Divisible by a Mersenne Prime

Part of the Lecture Notes in Computer Science book series (LNCS,volume 2667)

Abstract

Pseudo-random numbers with long periods and good statistical properties are often required for applications in computational finance. We consider the requirements for good uniform random number generators, and describe a class of generators whose period is a Mersenne prime or a small multiple of a Mersenne prime. These generators are based on “ almost primitive” trinomials, that is trinomials having a large primitive factor. They enable very fast vector/parallel implementations with excellent statistical properties.

Keywords

  • Random Number Generator
  • Irreducible Factor
  • Primitive Polynomial
  • Small Multiple
  • Good Statistical Property

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

This work was supported in part by the Oxford Centre for Computational Finance, the Oxford Supercomputing Centre, and EPSRC grant GR/N35366.

This is a preview of subscription content, access via your institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (Canada)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   84.99
Price excludes VAT (Canada)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   109.99
Price excludes VAT (Canada)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. S. L. Anderson, Random number generators on vector supercomputers and other advanced architectures, SIAM Review 32 (1990), 221–251.

    CrossRef  MATH  MathSciNet  Google Scholar 

  2. E. R. Berlekamp, Algebraic Coding Theory, McGraw-Hill, New York, 1968.

    MATH  Google Scholar 

  3. I. F. Blake, S. Gao and R. J. Lambert, Constructive problems for irreducible polynomials over finite fields, in Information Theory and Applications, Lecture Notes in Computer Science 793, Springer-Verlag, Berlin, 1994, 1–23.

    Google Scholar 

  4. I. F. Blake, S. Gao and R. Lambert, Construction and distribution problems for irreducible trinomials over finite fields, in Applications of Finite Fields (D. Gollmann, ed.), Oxford, Clarendon Press, 1996, 19–32. http://www.math.clemson.edu/~sgao/pub.html

    Google Scholar 

  5. R. P. Brent, Uniform random number generators for supercomputers, Proc. Fifth Australian Supercomputer Conference, Melbourne, December 1992, 95–104. http://www.comlab.ox.ac.uk/oucl/work/richard.brent/pub/pub132.html

  6. R. P. Brent, On the periods of generalized Fibonacci recurrences, Math. Comp. 63 (1994), 389–401. http://www.comlab.ox.ac.uk/oucl/work/richard.brent/pub/pub133.html

    CrossRef  MATH  MathSciNet  Google Scholar 

  7. R. P. Brent, Random number generation and simulation on vector and parallel computers, Lecture Notes in Computer Science 1470, Springer-Verlag, Berlin, 1998, 1–20. http://www.comlab.ox.ac.uk/oucl/work/richard.brent/pub/pub185.html

    Google Scholar 

  8. R. P. Brent, Some uniform and normal random number generators, version 1.03 (January 2002). Available from http://www.comlab.ox.ac.uk/oucl/work/richard.brent/random.html

  9. R. P. Brent, S. Larvala and P. Zimmermann, A fast algorithm for testing reducibility of trinomials mod 2 and some new primitive trinomials of degree 3021377, Math. Comp., to appear. Preprint and update available at http://www.comlab.ox.ac.uk/oucl/work/richard.brent/pub/pub199.html

  10. R. P. Brent and P. Zimmermann, Algorithms for finding almost irreducible and almost primitive trinomials, Proc. Conference in Honour of Professor H. C. Williams, Banff, Canada (May 2003), The Fields Institute, Toronto, to appear. Preprint available at http://www.comlab.ox.ac.uk/oucl/work/richard.brent/pub/pub212.html

    Google Scholar 

  11. P. D. Coddington, Random number generators for parallel computers, The NHSE Review 2 (1996). http://nhse.cs.rice.edu/NHSEreview/RNG/PRNGreview.ps

  12. A. Compagner and A. Hoogland, Maximum-length sequences, cellular automata, and random numbers, J. Computational Physics 71 (1987), 391–428.

    CrossRef  MATH  MathSciNet  Google Scholar 

  13. D. Coppersmith, H. Krawczyk and Y. Mansour, The shrinking generator, Lecture Notes in Computer Science 773 (1994), Springer-Verlag, Berlin, 22–39.

    Google Scholar 

  14. L. Devroye, Non-Uniform Random Variate Generation, Springer-Verlag, New York, 1986.

    MATH  Google Scholar 

  15. P. L’Ecuyer, Random numbers for simulation, Comm. ACM 33,10 (1990), 85–97.

    CrossRef  Google Scholar 

  16. A. M. Ferrenberg, D. P. Landau and Y. J. Wong, Monte Carlo simulations: hidden errors from “good” random number generators, Phys. Review Letters 69 (1992), 3382–3384.

    CrossRef  Google Scholar 

  17. J. von zur Gathen, Irreducible trinomials over finite fields, Math. Comp. 71 (2002), 1699–1734.

    CrossRef  MathSciNet  Google Scholar 

  18. J. E. Gentle, Random Number Generation and Monte Carlo Methods, Springer-Verlag, Berlin, 1998.

    MATH  Google Scholar 

  19. P. Gimeno, Problem with ran_array, personal communication, 10 Sept. 2001.

    Google Scholar 

  20. GIMPS, The Great Internet Mersenne Prime Search, http://www.mersenne.org/

  21. S. W. Golomb, Shift register sequences, Aegean Park Press, revised edition, 1982.

    Google Scholar 

  22. B. F. Green, J. E. K. Smith and L. Klem, Empirical tests of an additive random number generator, J. ACM 6 (1959), 527–537.

    CrossRef  MATH  MathSciNet  Google Scholar 

  23. J. R. Heringa, H. W. J. Blöte and A. Compagner, New primitive trinomials of Mersenne-exponent degrees for random-number generation, International J. of Modern Physics C 3 (1992), 561–564.

    CrossRef  MATH  Google Scholar 

  24. P. Jaeckel, Monte Carlo Methods in Finance, John Wiley and Sons, 2002.

    Google Scholar 

  25. F. James, A review of pseudorandom number generators, Computer Physics Communications 60 (1990), 329–344.

    CrossRef  MATH  MathSciNet  Google Scholar 

  26. D. E. Knuth, The Art of Computer Programming, Volume 2: Seminumerical Algorithms (third edition), Addison-Wesley, Menlo Park, CA, 1998.

    Google Scholar 

  27. D. E. Knuth, A better random number generator, January 2002, http://www-cs-faculty.stanford.edu/~knuth/news02.html

  28. T. Kumada, H. Leeb, Y. Kurita and M. Matsumoto, New primitive t-nomials (t = 3, 5) over GF(2) whose degree is a Mersenne exponent, Math. Comp. 69 (2000), 811–814. Corrigenda: ibid 71 (2002), 1337–1338.

    CrossRef  MATH  MathSciNet  Google Scholar 

  29. Y. Kurita and M. Matsumoto, Primitive t-nomials (t = 3, 5) over GF(2) whose degree is a Mersenne exponent ≤ 44497, Math. Comp. 56 (1991), 817–821.

    CrossRef  MATH  MathSciNet  Google Scholar 

  30. C. Lemieux and P. L’Ecuyer, On the use of quasi-Monte Carlo methods in computational finance, Lecture Notes in Computer Science 2073, Springer-Verlag, Berlin, 2001, 607–616.

    Google Scholar 

  31. R. Lidl and H. Niederreiter, Introduction to Finite Fields and their Applications, Cambridge Univ. Press, Cambridge, second edition, 1994.

    MATH  Google Scholar 

  32. M. Lüscher, A portable high-quality random number generator for lattice field theory simulations, Computer Physics Communications 79 (1994), 100–110.

    CrossRef  MATH  MathSciNet  Google Scholar 

  33. G. Marsaglia, A current view of random number generators, in Computer Science and Statistics: The Interface, Elsevier Science Publishers B. V.,1985, 3–10.

    Google Scholar 

  34. G. Marsaglia, Diehard, 1995. Available from http://stat.fsu.edu/~geo/

  35. G. Marsaglia and L. H. Tsay, Matrices and the structure of random number sequences, Linear Algebra Appl. 67 (1985), 147–156.

    CrossRef  MATH  MathSciNet  Google Scholar 

  36. M. Mascagni, M. L. Robinson, D. V. Pryor and S. A. Cuccaro, Parallel pseudorandom number generation using additive lagged-Fibonacci recursions, Lecture Notes in Statistics 106, Springer-Verlag, Berlin, 1995, 263–277.

    Google Scholar 

  37. M. Matsumoto and T. Nishimura, Mersenne twister: A 623-dimensionally equidistributed uniform pseudorandom number generator, ACM Transactions on Modeling and Computer Simulations 8, 1998, 3–30. Also http://www.math.keio.ac.jp/~matumoto/emt.html

    CrossRef  MATH  Google Scholar 

  38. A. J. Menezes, P. C. van Oorschot and S. A. Vanstone, Handbook of Applied Cryptography, CRC Press, New York, 1997. http://cacr.math.uwaterloo.ca/hac/

    MATH  Google Scholar 

  39. J. von Neumann, Various techniques used in connection with random digits, The Monte Carlo Method, National Bureau of Standards (USA), Applied Mathematics Series 12 (1951), 36.

    Google Scholar 

  40. H. Niederreiter, Random Number Generation and Quasi-Monte Carlo Methods, CBMS-NSF Regional Conference Series in Applied Mathematics 63, SIAM, Philadelphia, 1992.

    Google Scholar 

  41. S. K. Park and K. W. Miller, Random number generators: good ones are hard to find, Comm. ACM 31 (1988), 1192–1201.

    CrossRef  MathSciNet  Google Scholar 

  42. W. P. Petersen, Some vectorized random number generators for uniform, normal, and Poisson distributions for CRAY X-MP, J. Supercomputing 1 (1988), 327–335.

    CrossRef  Google Scholar 

  43. W. P. Petersen, Lagged Fibonacci series random number generators for the NECSX-3, Internat. J. High Speed Computing 6 (1994), 387–398.

    CrossRef  Google Scholar 

  44. J. F. Reiser, Analysis of Additive Random Number Generators, Ph. D. thesis and Technical Report STAN-CS-77-601, Stanford University, 1977.

    Google Scholar 

  45. E. R. Rodemich and H. Rumsey, Jr., Primitive trinomials of high degree, Math. Comp. 22 (1968), 863–865.

    CrossRef  MATH  MathSciNet  Google Scholar 

  46. L. N. Shchur, J. R. Heringa and H. W. J. Blöte, Simulation of a directed randomwalk model: the effect of pseudo-random-number correlations, Physica A 241 (1997), 579.

    CrossRef  Google Scholar 

  47. R. G. Swan, Factorization of polynomials over finite fields, Pacific J. Mathematics 12 (1962), 1099–1106.

    MATH  MathSciNet  Google Scholar 

  48. R. C. Tausworthe, Random numbers generated by linear recurrence modulo two, Math. Comp. 19 (1965), 201–209.

    CrossRef  MATH  MathSciNet  Google Scholar 

  49. S. Tezuka, Efficient and portable combined Tausworthe random number generators, ACM Trans. on Modeling and Computer Simulation 1 (1991), 99–112.

    CrossRef  MATH  Google Scholar 

  50. J. Tromp, L. Zhang and Y. Zhao, Small weight bases for Hamming codes, Theoretical Computer Science 181(2), 1997, 337–345.

    CrossRef  MATH  MathSciNet  Google Scholar 

  51. I. Vattulainen, T. Ala-Nissila and K. Kankaala, Physical tests for random numbers in simulations, Phys. Review Letters 73 (1994), 2513–2516.

    CrossRef  Google Scholar 

  52. S. S. Wagsta. et al., The Cunningham Project, http://www.cerias.purdue.edu/homes/ssw/cun/

  53. N. Zierler, Primitive trinomials whose degree is a Mersenne exponent, Information and Control 15 (1969), 67–69.

    CrossRef  MATH  MathSciNet  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and Permissions

Copyright information

© 2003 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Brent, R.P., Zimmermann, P. (2003). Random Number Generators with Period Divisible by a Mersenne Prime. In: Kumar, V., Gavrilova, M.L., Tan, C.J.K., L’Ecuyer, P. (eds) Computational Science and Its Applications — ICCSA 2003. ICCSA 2003. Lecture Notes in Computer Science, vol 2667. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-44839-X_1

Download citation

  • DOI: https://doi.org/10.1007/3-540-44839-X_1

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-40155-1

  • Online ISBN: 978-3-540-44839-6

  • eBook Packages: Springer Book Archive