This is the discrete event simulator I wrote for the EPSRC project OPSnet. It's written in C++ because it relies on the C++ STL. Note that the simulator uses the Mersenne twister random generator by default. This is implemented in the C++ header file MersenneTwister.h The traffic generator generates the packet destination, length and gap width (the time between 2 subsequent packets). The destination is a uniform distribution; the packet length and gap width can be generated using a number of different distributions. There are many variables defined as macros in the header file, you can use them to customise the simulator. The traffic_generator_gen_h.pl Perl script will create the header file and compile the source code. Look at the script and the source code for more info. To compile the simulator generator manually: g++ -O3 opsmodule.cc -o opsmodule