LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
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

Reply
 
LinkBack Search this Thread
Old 03-30-2013, 11:19 AM   #31
monajh
LQ Newbie
 
Registered: Feb 2013
Posts: 7

Rep: Reputation: Disabled
when i m running /mobility/leach.tcl in leach patch


i got error


can't read "opt(num_clusters)": no such element in array
while executing
"expr 1.5*$opt(num_clusters)"
invoked from within
"expr int([expr 1.5*$opt(num_clusters)])+1"
invoked from within
"set opt(spreading) [expr int([expr 1.5*$opt(num_clusters)])+1]"
(file "leach.tcl" line 14)


how to overcome this...
please help me.....
 
Old 03-30-2013, 11:22 AM   #32
monajh
LQ Newbie
 
Registered: Feb 2013
Posts: 7

Rep: Reputation: Disabled
query about leach patch

in leach patch which file i have to run for simulation??..
 
Old 05-16-2013, 05:43 PM   #33
doussa
LQ Newbie
 
Registered: Feb 2013
Posts: 29

Rep: Reputation: Disabled
Unhappy

hi
@deepa_2111
I try to integrate multihops in leach (intercluster communication) but results show that data transmetted to BS of the new protocol are << of those in leach and also the lifetime of the network in new leach is >> lifetime in leach or since the new one is just an amelioration of leach results must not be like this pleeeeeease I need your help deepa asap because I need this work next week.
this is the result of simulation of leach
Code:
At 530.90000000005216:
		Total Energy = 199.03419947307776
		Total Data = 54908
		Total Alive = 4

Simulation complete.
and the result of new leach is
Code:
At 681.80000000008647:
		Total Energy = 199.82747069490344
		Total Data = 13617
		Total Alive = 4

Simulation complete.
also I have this problem in new leach
Code:
I can hear 11 different packets ==> collision.
COLLISION!!!! rx_state_ = 0
and I don't know how to solve it please deepa I'm wating for your response and I will be gratful.
 
Old 05-16-2013, 11:59 PM   #34
SimK
LQ Newbie
 
Registered: May 2013
Posts: 2

Rep: Reputation: Disabled
Dear Sir
I have the following errors in leach.err, need help:
can't read "env(RCA_LIBRARY)": no such variable
while executing
"source $env(RCA_LIBRARY)/ns-ranode.tcl"
(file "mit/uAMPS/sims/uamps.tcl" line 9)
invoked from within
"source.orig mit/uAMPS/sims/uamps.tcl"
("uplevel" body line 1)
invoked from within
"uplevel source.orig[list $fileName]"
invoked from within
"if [$instance_ is_http_url $fileName] {
set buffer [$instance_ read_url $fileName]
uplevel eval $buffer
} else {
uplevel source.orig[list $fileName]
..."
(procedure "source" line 8)
invoked from within
"source mit/uAMPS/sims/uamps.tcl"
(file "tcl/mobility/leach.tcl" line 18)
invoked from within
"source.orig tcl/mobility/leach.tcl"
("uplevel" body line 1)
invoked from within
"uplevel source.orig[list $fileName]"
invoked from within
"if [$instance_ is_http_url $fileName] {
set buffer [$instance_ read_url $fileName]
uplevel eval $buffer
} else {
uplevel source.orig[list $fileName]
..."
(procedure "source" line 8)
invoked from within
"source tcl/mobility/$opt(rp).tcl"
(file "tcl/ex/wireless.tcl" line 187)
 
Old 05-17-2013, 07:11 AM   #35
doussa
LQ Newbie
 
Registered: Feb 2013
Posts: 29

Rep: Reputation: Disabled
Quote:
Originally Posted by SimK View Post
Dear Sir
I have the following errors in leach.err, need help:
can't read "env(RCA_LIBRARY)": no such variable
while executing
"source $env(RCA_LIBRARY)/ns-ranode.tcl"
(file "mit/uAMPS/sims/uamps.tcl" line 9)
invoked from within
"source.orig mit/uAMPS/sims/uamps.tcl"
("uplevel" body line 1)
invoked from within
"uplevel source.orig[list $fileName]"
invoked from within
"if [$instance_ is_http_url $fileName] {
set buffer [$instance_ read_url $fileName]
uplevel eval $buffer
} else {
uplevel source.orig[list $fileName]
..."
(procedure "source" line 8)
invoked from within
"source mit/uAMPS/sims/uamps.tcl"
(file "tcl/mobility/leach.tcl" line 18)
invoked from within
"source.orig tcl/mobility/leach.tcl"
("uplevel" body line 1)
invoked from within
"uplevel source.orig[list $fileName]"
invoked from within
"if [$instance_ is_http_url $fileName] {
set buffer [$instance_ read_url $fileName]
uplevel eval $buffer
} else {
uplevel source.orig[list $fileName]
..."
(procedure "source" line 8)
invoked from within
"source tcl/mobility/$opt(rp).tcl"
(file "tcl/ex/wireless.tcl" line 187)
hi,
you should replace
Code:
#source $env(RCA_LIBRARY)/ns-ranode.tcl
#source $env(uAMPS_LIBRARY)/ns-bsapp.tcl
#source $env(uAMPS_LIBRARY)/extras.tcl
#source $env(uAMPS_LIBRARY)/stats.tcl
in the file mit/uAMPS/sims/uamps.tcl by
Code:
source your path/ns-allinone-2.27/ns-2.27/mit/rca/ns-ranode.tcl
source your path/ns-allinone-2.27/ns-2.27/mit/uAMPS/ns-bsapp.tcl
source your path/ns-allinone-2.27/ns-2.27/mit/uAMPS/extras.tcl
source your path/ns-allinone-2.27/ns-2.27/mit/uAMPS/stats.tcl
I hope that helps you.
 
Old 05-17-2013, 07:12 AM   #36
doussa
LQ Newbie
 
Registered: Feb 2013
Posts: 29

Rep: Reputation: Disabled
Quote:
Originally Posted by doussa View Post
hi
@deepa_2111
I try to integrate multihops in leach (intercluster communication) but results show that data transmetted to BS of the new protocol are << of those in leach and also the lifetime of the network in new leach is >> lifetime in leach or since the new one is just an amelioration of leach results must not be like this pleeeeeease I need your help deepa asap because I need this work next week.
this is the result of simulation of leach
Code:
At 530.90000000005216:
		Total Energy = 199.03419947307776
		Total Data = 54908
		Total Alive = 4

Simulation complete.
and the result of new leach is
Code:
At 681.80000000008647:
		Total Energy = 199.82747069490344
		Total Data = 13617
		Total Alive = 4

Simulation complete.
also I have this problem in new leach
Code:
I can hear 11 different packets ==> collision.
COLLISION!!!! rx_state_ = 0
and I don't know how to solve it please deepa I'm wating for your response and I will be gratful.
plllllease I need your help asap!!!!!!
 
Old 07-08-2013, 04:06 AM   #37
DeepaliDeshpande
LQ Newbie
 
Registered: Jul 2013
Posts: 11

Rep: Reputation: Disabled
Leach

Hi newly joined member
I need help in finding remaining energy by modifying stats.tcl file in leach patch.
please help me iam ME student
 
  


Reply

Tags
leach


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Differences between LEACH results on ns2.1b5 and ns2.35 deepa_2111 Linux - Software 15 05-16-2013 05:53 PM
patch for working leach protocol in ns2.34 fedora rajcek Linux - Wireless Networking 4 02-04-2013 06:59 AM
LEACH protocol installation on NS2.27 Scofield Linux - General 255 03-08-2012 05:19 PM
codes for leach protocol in ns2 shaddrack yaw nusenu Linux - Newbie 2 02-23-2011 02:56 PM


All times are GMT -5. The time now is 03:55 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration