Sunday, October 12, 2008

Learning NS2

Now you have installed NS2 successfully....Its time for next step, learn the basics and then move on to advanced stuff. There are a lot of resources available in web on ns-2. I have enclosed web-links to some of the resources in this post, for more resources just Google it.
To program NS-2 you need to know C++, TCL and OTCL.
It would be advantageous if you are well versed with C++ programming.If you are a novice, no need to panic, to learn C++ there are a large number of books available.The best book to follow is "C++ Programing Language" by Bjarne Stroustrap. This book is a big one and needs some time to read.You can also refer a large number of resources available freely on C++ in the web, just use Google to search them.
To learn TCL the best book is "Practical programming in TCL/TK" by Brent B Welch. For TCL also you can find a large number of resources in the web.
OTCL is an Object Oriented extension to TCL.I dont think, there are any printed books available on OTCL.

You can refer the below sites for Introduction and Tutorials on OTCL:
For Introduction to OTCL refer : http://en.wikipedia.org/wiki/OTcl
This one is a very good tutorial to OTCL : http://bmrc.berkeley.edu/research/cmt/cmtdoc/otcl/
This site has a short tutorial on OTCL : http://nile.wpi.edu/NS/otcl.html
The NS-Manual available at www.isi.edu/nsnam/ns/doc/ also has a brief introduction to OTCL concepts.

After getting familiar with C++, TCL & OTCL concepts, you can directly start learning the NS-2.

The best resource to start with, is Greiss Tutorial which can be found at http://www.isi.edu/nsnam/ns/tutorial/index.html
Greiss Tutorial is a hands-on tutorial which covers the basics of NS-2. It is better to execute all the programs in this tutorial.

The below web-sites have links to other ns-2 resources
http://www.cse.msu.edu/~wangbo1/ns2/
http://www.matlab.nitech.ac.jp/~khpoo/research/ns2.html
http://www.winlab.rutgers.edu/~zhibinwu/html/network_simulator_2.html

There are a large number of Power Point slides available in web on NS-2. I am here-by enclosing the link to the Google search page on NS-2 PPT's
http://www.google.co.in/search?hl=en&q=NS2+filetype%3Appt&btnG=Search&meta=

After reading the above resources you can start reading the NS-Manual found at site
http://www.isi.edu/nsnam/ns/doc/

This document can also be found in your ns-allinone-2.33 directory at
~/ns-allinone-2.33/ns-2.33/doc/everything.pdf

Hope would be Useful.............

Happy Learning :)
All The Best :)







2 comments:

uhanya ece said...

I need code to calculate remaining energy level of nodes in NS2. could anybody help me?

Monika Verma said...

hi...
i need ns2 code of sinkhole attack for manet...could anybody help me plz....