Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello My friend
Really new in ns2 and I am installing leach protocols (mit-uAMPS) in ns-2.35 and success to run the leach_test and wireless.tcl and get no error and there are leach.tr and leach.out .
My problems are I have my own scenarios which I make it in setdest in ns2
how I can apply this scenario in leach protocol and the change must do in wireless.tcl and leach_test .
Also I need the Packet delivery ratio (PDF) how I can calculate it in leach from leach.tr or leach.out
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,493
Rep:
Quote:
I have my own scenarios which I make it in setdest in ns2
Please read wireless.tcl to know that a scenario file is already used :
Like ../mobility/scene/scen-670x670-50-600-20-0, or scen-670x670-50-600-20-2.
(Line number : $ grep -n mobility wireless.tcl ) (The "cbr" traffic file will also be listed.)
So you can just try adding your own file specs to wireless.tcl, and the file(s) to tcl/mobility
About Packet delivery ratio, PDF :
Find a file.awk in awk#perl#python__scripts-1-2017.tar.gz (~170 scripts) that can work with your file https://drive.google.com/file/d/0B7S...ew?usp=sharing
List :
all.awk
Pdf-0.awk
pdf.awk
PDR.awk
PacketDeliveryFraction.awk
PacketDeliveryRatio.awk
Thank you very much knudfl to fast answer
I put my scenario in the wireless.tcl and there is no errors
My question is ... there are also scenario in the leach_test file must I change it or not ? also the result for simulation for leach protocols in leach.tr or leach.out ?
LEACH Resulats
I hope all have a nice day
I installed Mit-uAmps in Ns-2.35 and run leach_test and No error in leach.err My problem When I need to calculate the packet send and packets drop and PDR from leach.tr by using AWK I get different results in each time I run leach_test.
Please, any body can help me for that.
I want to thanks again knudfl Really I check seed it is 0 in all places, and it is the same problem the result is different when run leach_test and read results from leach.tr please see the attach files maybe u can help me.
thanks knudfl
I want to thanks again knudfl Really I check seed it is 0 in all places, and it is the same problem the result is different when run leach_test and read results from leach.tr please see the attach files maybe u can help me.
thanks knudfl
Sorry, but do you really not understand what a random number is??? It STARTS with 0...and generates a random number. It will NEVER be the same twice.
Really I understand what you mean But? I want to make comparative and I fix the number of nodes and all parameters and when run Leach_ test and see the results when nodes are 50 and nodes are 100 it's same PDR and packet lsot and etc ... I am new in this field.
Thanks
Last edited by ITengineer; 04-06-2017 at 05:36 AM.
Really I understand what you mean But? I want to make comparative and I fix the number of nodes and all parameters and want run Leach_ test and see the results when nodes are 50 and nodes are 100. I am new in this field .
And you are seeing those results. The 'field' doesn't matter in this context....a random number is just that: RANDOM. You won't get the same results twice. Not sure what you don't understand about that....
Thanks TB0ne
I want to make comparative and I fix the number of nodes and all parameters. when running leach_test twice the results of PDR, packet lost and etc ...which read it from leach.tr different in each time and I don't change any parameters I thought if I don't change the parameters results must be same . But I get not same when running leach_test
Thanks
Last edited by ITengineer; 04-06-2017 at 05:47 AM.
Thanks TB0ne
I want to make comparative and I fix the number of nodes and all parameters. when running leach_test twice the results of PDR, packet lost and etc ...which read it from leach.tr different in each time and I don't change any parameters I thought if I don't change the parameters results must be same . But I get not same when running leach_test
Thanks
YOU ARE USING A RANDOM NUMBER GENERATOR...IT WILL GENERATE RANDOM NUMBERS. How, exactly do you think you'll get the same results twice with random values???? What do you not understand about this???? The seed is where the random number pool STARTS from.
If you truly can't understand that, then you need to ask your teacher to explain what a random number is.
Thank you very much knudf for your cooperation. I now understand that But I have another question why always receive in zero PLeease if you guide me to solve this problem
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.