Terms Packet delivery ratio, Packet Lost, End to end delay
If you want to evaluate the performance of protocol using NS-2, first you have to define the evaluation criteria. This time I want to explore about Packet delivery ratio, packet lost and end to end delay.What are they?
Packet delivery ratio : the ratio of the number of delivered data packet to the destination. This illustrates the level of delivered data to the destination.The greater value of packet delivery ratio means the better performance of the protocol.
∑ Number of packet receive / ∑ Number of packet send
End-to-end Delay : the average time taken by a data packet to arrive in the destination. It also includes the delay caused by route discovery process and the queue in data packet transmission. Only the data packets that successfully delivered to destinations that counted.The lower value of end to end delay means the better performance of the protocol.
∑ ( arrive time – send time ) / ∑ Number of connections
Packet Lost : the total number of packets dropped during the simulation.The lower value of the packet lost means the better performance of the protocol.
Packet lost = Number of packet send – Number of packet received .
How to analyze trace file to find the result?
First : you must analyze the trace file with this Script PDR and E2ED
run this script with command :
awk -f PacketDeliveryRatio.awk (name trace file.tr)
awk -f Endtoenddelay.awk (name trace file.tr)
If error
This is exactly what I need. However I couldn’t run the command. Probably I misunderstood something. On what file should I run “awk -f Endtoenddelay.awk (name trace file.tr)”
I downloaded the text file you provided, saved it as .awk file and run it like “awk -f pdr.awk ~/Desktop/mypackets.trace” but it returns all 0’s.
Solution
1. you must execute the awk files inside folder that contain your trace files.
2. please make sure that you are using new trace file format or old trace file format. you can check this type in your tcl schenario script.
how can i enable the new trace file format not the old one in the tcl script ?
For example in this tcl files :
If Division by zero error
Please check your trace files. Make sure that you use new trace format or old trace format.
After that changes the number of variable.
For Example:
Based on trace format bellow, the time variable is in row 3. so put $3 in your variable definition. In this case time=$3;
Hi when i type this command for delay i don’t have any result what’s the problem ??
After that changes the number of variable.
For Example:
Based on trace format bellow, the time variable is in row 3. so put $3 in your variable definition. In this case time=$3;