[ndnSIM] Zipf-Mandelbrot Patch for ndnSIM
Xiaoke Jiang
shock.jiang at gmail.com
Mon Dec 24 19:09:45 PST 2012
Dear All,
I have implemented an app which requests contents following Zipf-Mandelbrot distribution (number of Content frequency Distribution). This class is subclass of ConsumerCbr.
My change includes:
1) modify ConsumerCbr.h, make its private members to protected, which allow ConsumberZipfManbelbrot to access those members.
2) add an 2 file, consumber-zipf-mandelbrot.{h, cc} in ndnSIM/apps/
Usage is very simple, just as what you do to ConsumerCbr,
ndn::AppHelper consumerHelper ("ns3::ndn::ConsumerZipfMandelbrot");
//ndn::AppHelper consumerHelper ("ns3::ndn::ConsumerCbr");
consumerHelper.SetPrefix (prefix);
consumerHelper.SetAttribute ("Frequency", StringValue ("100")); // 100 interests a second
//consumerHelper.SetAttribute ("Randomize", StringValue ("uniform")); // 100 interests a second
of course, I have written some script to test it, I put it into ndnSIM/example/ndn-zipf-mandelbrot.cc
I will share it with github with Alex's help, I hope it may help you.
thanks
My Regards,
Xiaoke Jiang
Ph.D Candidate,
Dept. of Computer Science and Technology,
Tsinghua University, P. R. China
More information about the ndnSIM
mailing list