Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
|
|
|
03-14-2013, 07:07 AM
|
#421
|
Member
Registered: Apr 2011
Distribution: -
Posts: 185
|
@rakesh:
No. of nodes alive at the end of a round is the same as network lifetime.
I didnt use xgraph ... so can't suggest anything.
Quote:
Originally Posted by rakeshpanchiwala
@deepa 2111
Thanks for your reply...........
I have plotted my graph as you described but i want to plot graph of network lifetime and remaining energy. so please give me quick reply its urgent.
I also want to compare that results in xgraph but it only plots one graph. If possible to compare in xgraph then Please give me quick reply.
|
|
|
|
03-14-2013, 07:11 AM
|
#422
|
Member
Registered: Apr 2011
Distribution: -
Posts: 185
|
@nmmn134
I saw the same .. leach was better than leach-c.
I can only assume that this is due to the differences between ns2.35 (which i used) and ns2.1 (which Heinzelman) used ... There are significant differences in the implementation on the wireless channel.
However, the shape of my plots match those in the thesis for leach-c too ... and hence, i assumed my simulation was fine.
Quote:
Originally Posted by nmmn134
@ deepa 2111
I already run Leach and Leach-c. But my result of leach is better than result of leach-c. why this for result ?
Please help me !
Leach.out
|
|
|
|
03-14-2013, 08:58 AM
|
#423
|
LQ Newbie
Registered: Mar 2013
Posts: 14
Rep:
|
@deepa 2111
thx a lotttttttttt i changed the energy.cc and wireless-phy.cc as u said and my nergy is < 200 J
GOD bless u.thx a lot
Last edited by emma166; 03-14-2013 at 08:51 PM.
|
|
|
03-14-2013, 10:42 AM
|
#424
|
LQ Newbie
Registered: Dec 2012
Posts: 12
Rep:
|
@deepa 2111
Thanks for your reply.
But i want to calculate remaining energy after each round to plot graph.
|
|
|
03-14-2013, 11:19 AM
|
#425
|
LQ Newbie
Registered: Feb 2013
Posts: 3
Rep:
|
Result of Leach & Leach-c
I install exidus-pegasis_ns-234-leach.tar of exidus. The result seems reasonable. Leach-c was better than Leach because Leach-c was develop from leach.
the plot.
http://www.linuxquestions.org/questi...1&d=1363277097
|
|
1 members found this post helpful.
|
03-15-2013, 02:27 PM
|
#426
|
LQ Newbie
Registered: Mar 2013
Posts: 14
Rep:
|
Quote:
Originally Posted by deepa_2111
@rakesh:
No. of nodes alive at the end of a round is the same as network lifetime.
I didnt use xgraph ... so can't suggest anything.
|
hi deepa2111
please i want to plot leach.alive leach .data and leach.energy (i'm using gnuplot) but i don't know really how to do that,i tried to use this command (plot "leach.X" 1:3 using lines; by the way X here is data,energy or alive) but the graphs that i got are really so strange and don't match with the theoric results !!! could u please help me and tell me what should i do exactly ??
thx in advance.
|
|
1 members found this post helpful.
|
03-18-2013, 02:30 PM
|
#427
|
LQ Newbie
Registered: Mar 2013
Posts: 6
Rep:
|
i want to know how to get correct .nam file for leach
i added following code in WIRELESS.TCL
set nf [open $opt(rp).nam w]
$ns_ namtrace-all-wireless $nf $opt(x) $opt(y)
but in leach.nam file i am getting following output and its not working or showing simulation in nam(just empty window)
V -t * -v 1.0a5 -a 0
W -t * -x 1000 -y 1000
A -t * -n 1 -p 0 -o 0xffffffff -c 31 -a 1
A -t * -h 1 -m 2147483647 -s 0
please tell how to do correct simulation with correct output in leach.nam file asap.
thanx in advance..
|
|
1 members found this post helpful.
|
03-20-2013, 05:46 PM
|
#428
|
LQ Newbie
Registered: Mar 2013
Posts: 11
Rep:
|
recovering energy of node in ns-leach.tcl
hello every one i am doing some modifications in ns-leach.tcl and i am stuck in how to recover the energy of node to know who has the biggest one so i can chose it like second cluster head plz help me
|
|
|
03-20-2013, 08:09 PM
|
#429
|
LQ Newbie
Registered: Feb 2013
Posts: 3
Rep:
|
Quote:
Originally Posted by deepa_2111
Are there any files in leach_sims ? for example, leach.err ?
What do you mean by "and I reached leach.out" ???
And did you made a folder called "ns-234-leach". If so, have u modified the leach_test file (line that says dirname="mit/leach_sims") accordingly?
|
What and how to modify that...plz describe step by step...
I m stuck on the problem:
"In member function ‘void CMUTrace::format_rca(Packet*, int)’:
trace/cmu-trace.cc:1531: error: ‘A’ was not declared in this scope
trace/cmu-trace.cc:1535: error: ‘R’ was not declared in this scope
trace/cmu-trace.cc:1539: error: ‘D’ was not declared in this scope
make: *** [trace/cmu-trace.o] Error 1"
root@ubuntu:/home/raju/ns-allinone-2.34/ns-2.34#
plz plz help.. how to solv???????????
|
|
|
03-21-2013, 09:28 AM
|
#430
|
LQ Newbie
Registered: Mar 2013
Posts: 11
Rep:
|
choose a vice cluster head in leach
this is my code to select a vice cluster head among cluster nodes, according to their energy, the cluster head chooses among its member , the node with the highest energy . this is the code
# Set the TDMA schedule and send it to all nodes in the cluster.
set TDMA $clusterNodes_
set Ei 0
set nodeID [$self nodeID]
set element $nodeID
foreach element $TDMA {
set E [[$self getER] query]
puts " energy est $E "
if { $Ei < $E } {
set Ei $E
}
}
set SCH $element
puts " le vice cluster de CH $chID est $SCH "
-->the result (energy nodes of each cluster are equal)
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
energy est 1.4088472606115843
the vice cluster head of CH 7 is 23
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
energy est 1.3976149376339855
the vice cluster head of CH 10 is 42
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
energy est 1.4792380219880841
the vice cluster head of CH 25 is 53
energy est 1.3267670010478381
energy est 1.3267670010478381
energy est 1.3267670010478381
energy est 1.3267670010478381
the vice cluster head of CH 56 is 27
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
energy est 1.5025911961133158
the vice cluster head of CH 59 is 88
|
|
|
04-04-2013, 03:19 AM
|
#431
|
LQ Newbie
Registered: Feb 2013
Posts: 15
Rep:
|
Xgraph
@rakeshpanchiwala
Quote:
Originally Posted by rakeshpanchiwala
Thanks for your reply...........
I have plotted my graph as you described but i want to plot graph of network lifetime and remaining energy. so please give me quick reply its urgent.
I also want to compare that results in xgraph but it only plots one graph. If possible to compare in xgraph then Please give me quick reply.
|
Could you please tell me how did you plot it please.and did you use AWk script or not.
Thank you
|
|
|
04-08-2013, 12:55 AM
|
#432
|
LQ Newbie
Registered: Dec 2012
Posts: 12
Rep:
|
@lavender
I have plotted graph in xgraph format. Does not need any awk script.
|
|
|
04-08-2013, 06:07 AM
|
#433
|
LQ Newbie
Registered: Feb 2013
Posts: 15
Rep:
|
could you tell me how ?
Quote:
Originally Posted by rakeshpanchiwala
@rakeshpanchiwala
I have plotted graph in xgraph format. Does not need any awk script.
|
Could you Tell me how please? and i will be grateful.
|
|
|
04-09-2013, 07:02 PM
|
#434
|
LQ Newbie
Registered: Feb 2013
Posts: 15
Rep:
|
@Deepa 2111
please when i run the simulation of leach the output was
At 524.60000000005073:
Total Energy = 199.88864065249675
Total Data = 53086
Total Alive = 4
Simulation complete.
even if in the PhD thesis by Heinzelman the time was more than this could you tell me what is the problem please ?
|
|
|
04-10-2013, 01:27 AM
|
#435
|
LQ Newbie
Registered: Apr 2013
Posts: 6
Rep:
|
dsr routing protocol modification
hello sir i harshil
i want to modification in DSR routing protocl by using some code in dsr.cc file .i want to add this code in dsr.cc but some error is generated so plese help me.this code for acknolodgment reply for imrove performance of dsr
void MDSRAgent::getRouteForPacket(SRPacket &p, bool retry)
{
Entry *e = request_table.getEntry(p.dest);
Time time = Scheduler::instance().clock();
if snooze==1&&recv.ACK==1
SRPacket rrp = p;
rrp.pkt = p.pkt->copy();
hdr_sr *srh = hdr_sr::access(rrp.pkt);
hdr_ip *iph = hdr_ip::access(rrp.pkt);
hdr_cmn *cmh = hdr_cmn::access(rrp.pkt);
iph>daddr()=Address::instance().create_ipaddr(p.dest.getNSAddr_t(),RT_PORT);
iph->dport() = RT_PORT;
iph>saddr()=Address::instance().create_ipaddr(net_id.getNSAddr_t(),RT_PORT);
iph->sport() = RT_PORT;
cmnh->ptype() = PT_DSR;
cmnh->size() = size_;
cmnh->num_forwards() = 0;
}#endif
|
|
|
All times are GMT -5. The time now is 01:46 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|