Abstract
The ns-2 network simulator is one of the most widely used packet network simulators. Since version 2.1b9, it uses the MRG32k3a random number generator (RNG) proposed by L’Ecuyer, replacing the previous minimal standard multiplicative linear congruential generator by Park and Miller to remedy the problems of sensitivity to seeds and short-period length. Unfortunately, due to bad documentation and re-use of old scripts many people still wrongly use the old API functions to explicitly set seeds. While the old RNG required this, in the current MRG32k3 implementation the same approach leads to overriding the automatic seed generation of the new generator which can result in correlation between the generated random values. Using a wired and a wireless scenario we illustrate possible effects on simulation results. As the ns-2 community relies heavily on exchanging hints and scripts, which keep re-infecting the knowledge-base even years after the introduction of the new RNG we believe that this might affect the majority of all ns-2 simulation results currently published.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
References
nsnam web pages, http://www.isi.edu/nsnam/, last visited: Jul. 2007.
K. John: Ousterhout: Tcl and the Tk Toolkit, Addison-Wesley, Reading, MA, USA, ISBN 0-201-63337-X, 1994.
S.K. Park and R.W. Miller: Random number generation: Good ones are hard to find. Communications of the ACM, 31(10), 1192–1201, Oct. 1988.
B. Hechenleitner and K. Entacher: On Shortcomings of the ns-2 Random Number Generator. In T. Znati and B. McDonald, eds., Communication Networks and Distributed Systems Modeling and Simulation (CNDS), 2002.
P. L’Ecuyer: Good parameters and implementations for combined multiple recursive random number generators. Operations Research, 47(1), 159–164, 1999.
K. Fall and K. Varadhan (Eds.): The ns Manual (formerly ns Notes and Documentation), http://www.isi.edu/nsnam/ns/ns-documentation.html, last visited: Oct. 2006.
E. Altman and T. Jimenez: ns-2 for Beginners, lecture notes, Dec. 2003, http://www-sop.inria.fr/maestro/personnel/Eitan.Altman/COURS-NS/n3.pdf, last visited: Oct. 2006.
ns-users mailing list, ns-users@isi.edu, subscription on the Web via http://mailman.isi.edu/mailman/listinfo/ns-users, last visited: Jul. 2007.
K. Pawlikowski, H.-D.J. Jeong, and J.-S.R. Lee: On Credibility of Simulation Studies of Telecommunication Networks. IEEE Communications Magazine, 40(1), 132–139, Jan. 2002.
S. Kurkowski, T. Camp, M. Colagrosso: MANET Simulation Studies: The Incredibles, ACM SIGMOBILE Mobile Computing and Communications Review, 9(4), Oct. 2005.
P. L'Ecuyer: Random Number Generation, Chapter 2 of the Handbook of Computational Statistics, J.E. Gentle, W. Haerdle, and Y. Mori, eds., Springer-Verlag, New York, 2004, 35–70.
Pierre L’Ecuyer et al.: An object-oriented random number package with many long streams and substreams. Operations Research, 50(6), 1073–1075, 2002.
M. Umlauft and P. Reichl: Experiences with the ns-2 network simulator – explicitly setting seeds considered harmful. In Proc. Wireless Telecommunications Symposium (WTS), April 2007, Pomona, CA, USA.
Acknowledgments
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2009 Springer Science+Business Media, LLC
About this chapter
Cite this chapter
Umlauft, M., Reichl, P. (2009). Getting Network Simulation Basics Right – A Note on Seed Setting Effects for the ns-2 Random Number Generator. In: Powell, S., Shim, J. (eds) Wireless Technology. Lecture Notes in Electrical Engineering, vol 44. Springer, Boston, MA. https://doi.org/10.1007/978-0-387-71787-6_14
Download citation
DOI: https://doi.org/10.1007/978-0-387-71787-6_14
Published:
Publisher Name: Springer, Boston, MA
Print ISBN: 978-0-387-71786-9
Online ISBN: 978-0-387-71787-6
eBook Packages: EngineeringEngineering (R0)