Error: a script about Mesh

51 views
Skip to first unread message

George Paul

unread,
Feb 19, 2018, 9:22:20 AM2/19/18
to ns-3-users
Hi,

I have written a script. But it doesn’t work as I expect. Please forgive my ignorance. Maybe my mistake is obvious.

I have been modified for a long time but the problem is still not solved. I use the mailing list and have not got a reply yet.

In this script I added a computing module to calculate the packet loss rate, throughput, and delay.

However, the simulation result showed that the packet loss rate is one hundred percent. That is to say, the receiving node has not received any data.

Can you give me some suggestions to solve the problem? The source code is in the attachment. According to the guidance of the ns-3 website, I have explained the script at the beginning of the file.

It’s very kind of you to guide me.

Sincerely,

George.
newmesh.cc

Tommaso Pecorella

unread,
Feb 20, 2018, 8:05:04 PM2/20/18
to ns-3-users
Hi,

you're calculating the stats before the simulation, and not after.

It should be:
  Simulator::Run ();
  throughput
(monitor,&flowmon);


T.

George Paul

unread,
Feb 20, 2018, 8:37:17 PM2/20/18
to ns-3-users
Dear T,
Thank you for your help. Forgive my dull, I will work hard.
P.
在 2018年2月21日星期三 UTC+8上午9:05:04,Tommaso Pecorella写道:
Reply all
Reply to author
Forward
0 new messages