Tuesday, 31 March 2015

NS2 : Xgraph Utility Example


   In this post I have included an NS2 Script (TCL Script) calling the Xgraph utility to plot the graph.

The Xgraph utility is called by the following line of code in the TCL Script,

exec xgraph out0.tr out1.tr out2.tr -geometry 800x400 &


The three files out0.tr, out1.tr and out2.tr contains the input data for Xgraph. To learn about the data format of Xgraph input files read my post Xgraph for plotting in NS-2.
Executing The TCL Script

NAM Window Showing the Simulated Network

NAM Showing Traffic Flow

Graph Plotted Using Xgraph



No comments:

Post a Comment