LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking > Linux - Wireless Networking
User Name
Password
Linux - Wireless Networking This forum is for the discussion of wireless networking in Linux.

Notices


Reply
  Search this Thread
Old 04-20-2015, 04:36 AM   #76
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641

Re #75.

Please do not quote entire posts. A "one word reference" will do.
And don't use text speak / sms speak !
. http://en.wikipedia.org/wiki/Etiquet...ogy#Netiquette

The file to use for Xgraph is leach-c.data.txt .
`leach-c.data' https://drive.google.com/file/d/0B7S...ew?usp=sharing
-
Attached Files
File Type: txt leach-c.data.txt (309 Bytes, 25 views)
 
Old 04-20-2015, 05:48 AM   #77
emprit
Member
 
Registered: Feb 2015
Location: jl. bogor 1 no 91, malang, jawa timur, indonesia
Distribution: any linux
Posts: 81

Rep: Reputation: Disabled
what mean don't use text speak / sms speak !
 
Old 04-20-2015, 06:11 AM   #78
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Re #77.

"ur" is text speak. The real word/spelling is "your".
 
Old 04-20-2015, 06:58 AM   #79
emprit
Member
 
Registered: Feb 2015
Location: jl. bogor 1 no 91, malang, jawa timur, indonesia
Distribution: any linux
Posts: 81

Rep: Reputation: Disabled
ow ok, i will remember that. thanks
 
Old 04-22-2015, 02:50 AM   #80
ghadghoud
LQ Newbie
 
Registered: Apr 2015
Posts: 11

Rep: Reputation: Disabled
Hello everybody
As we know the cluster-head in leach agregates data to send it to the base .
And it also implements redundancy .
Where can i see that in the code ? In which .tcl ?
Thank you
 
Old 04-22-2015, 05:57 AM   #81
emprit
Member
 
Registered: Feb 2015
Location: jl. bogor 1 no 91, malang, jawa timur, indonesia
Distribution: any linux
Posts: 81

Rep: Reputation: Disabled
idk, but agregates data for leach at ns-leach.tcl
Code:
Application/LEACH instproc recvDATA {msg} {

  global ns_ opt
  $self instvar TDMAschedule_ receivedFrom_ dataReceived_

  set chID [$self nodeID]
  set nodeID [lindex $msg 0]
  pp "CH $chID received data ($msg) from $nodeID at [$ns_ now] - ns-leach.tcl"
  set receivedFrom_ [lappend receivedFrom_ $nodeID]

  set last_node [expr [llength $TDMAschedule_] - 1]
  if {$chID == [lindex $TDMAschedule_ $last_node]} {
    set last_node [expr $last_node - 1]
  }
  if {$nodeID == [lindex $TDMAschedule_ $last_node]} {
    # After an entire frame of data has been received, the cluster-head
    # must perform data aggregation functions and transmit the aggregate
    # signal to the base station.
    pp "CH $chID must now perform comp and xmit to BS. - ns-leach.tcl"
    set num_sigs [llength $TDMAschedule_]
    set compute_energy [bf $opt(sig_size) $num_sigs]
    pp "\tcompute_energy = $compute_energy - ns-leach.tcl"
    [$self getER] remove $compute_energy
    set receivedFrom_ [lappend receivedFrom_ $chID]
    set dataReceived_ $receivedFrom_
    set receivedFrom_ ""

    $self SendDataToBS
  }
}
 
Old 04-22-2015, 06:25 AM   #82
ghadghoud
LQ Newbie
 
Registered: Apr 2015
Posts: 11

Rep: Reputation: Disabled
Thank you ! But where we can see redundancy also ?
 
Old 04-24-2015, 03:59 AM   #83
emprit
Member
 
Registered: Feb 2015
Location: jl. bogor 1 no 91, malang, jawa timur, indonesia
Distribution: any linux
Posts: 81

Rep: Reputation: Disabled
@knudfl
sir i have problem, when i set 13 cluster my leach-c finish to early at 20s.
Code:
t 20: - mit/uAMPS/stats.tcl
		Total Energy = 27.862826740743788
		Total Data = 1935
		Total Alive = 96

BS Received data 40 , 10.362460469054881 from 40 at time 20.027104310090241 - mit/uAMPS/ns-bsapp.tcl 
This represents data from nodes: 25 61 64 72 76 97 40 - mit/uAMPS/ns-bsapp.tcl
Only received info from 0 nodes. - mit/uAMPS/ns-bsapp.tcl
There are currently 96 alive ==>  14 cluster-heads needed. - mit/uAMPS/ns-bsapp.tcl

At 20.029599999999999: - mit/uAMPS/stats.tcl
		Total Energy = 27.867691302444101
		Total Data = 1942
		Total Alive = 96

Simulation complete. - mit/uAMPS/stats.tcl
node alive
at alive.txt
at time 20.029599999999999 total node alive 96

please help
 
Old 05-08-2015, 02:32 AM   #84
wellytg
LQ Newbie
 
Registered: Nov 2014
Location: India
Distribution: Ubuntu 14.04
Posts: 6

Original Poster
Rep: Reputation: Disabled
output file not consistent

Hello am back after a few edits on the mit.tar leach i got some inconsistent results in the leach.out file , there are multiple instances of this error line 311, 418-

Code:
311 Warning dst_ is no longer being supported in NS. dst_ 0xffffffff
Use dst_addr_ and dst_port_ instead
although the simulation is runnung to the end and giving results i noticed @Knudfl your recent run does not have these warnings infact the 2 files are different


I have attached my file and the comparison one, Do the warning have any effect and how do I remove them??? Kindly assist

My output file https://drive.google.com/file/d/0Bz6...ew?usp=sharing

Knudfl output file https://drive.google.com/file/d/0B7S...bEU/view?pli=1

Last edited by wellytg; 05-08-2015 at 02:33 AM. Reason: wrong names
 
Old 05-08-2015, 05:09 AM   #85
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Re #84.

""edits on the mit.tar"" :
Which edits ? Which `mit.tar' ? ? mit.tar = unknown file.
(There are no edits to do with `leach+pegasis-ns234-files-2.tar.gz'.)


""311 Warning dst_ is no longer being supported""
A warning can be ignored. Is just an informational text.
But : The errors at the file end (leachout.txt.out?) are crucial :
Code:
At 502.30000000004571: - mit/uAMPS/stats.tcl
		Total Energy = 328.286714546854
		Total Data = 51150
		Total Alive = 4

ns: _o1442 checkAlive: can't read "sens_energy": no such variable
    while executing
"close $sens_energy"
    (procedure "sens_close_stats" line 8)
    invoked from within
"sens_close_stats"
    (procedure "sens_finish" line 4)
    invoked from within
"sens_finish"
    (procedure "_o1442" line 41)
    (Application/LEACH checkAlive line 41)
    invoked from within
"_o1442 checkAlive"
So which "leach / mit code" are you using ? ?
Which ns2 version ?
. http://www.linuxquestions.org/linux/...Ask_a_Question
. http://www.catb.org/~esr/faqs/smart-questions.html



-

Last edited by knudfl; 05-08-2015 at 05:11 AM.
 
Old 05-08-2015, 09:19 AM   #86
wellytg
LQ Newbie
 
Registered: Nov 2014
Location: India
Distribution: Ubuntu 14.04
Posts: 6

Original Poster
Rep: Reputation: Disabled
After fiddling around i got this one to work... I did side by side comparison with @exidus files, i then appended the extra code for producing results leach.alive.txt, leach.data.txt and leach.energy.txt,
I think that is responsible for the last lines in the leach.out

My setup is

Ubuntu 10.04 32bit /// also working on Centos 6.6
gcc 3.3.6 "manual install from author site"
ns2.27

mit.tar i used ..https://docs.google.com/file/d/0B7S2...&ddrp=1&hl=en#

instructions i used http://home.elka.pw.edu.pl/~iwindyga...c/ns2leach.pdf



@knudfl could you please share with me your latest run results of the @exidus these file conditions.txt leach.out, leach.alive.txt, leach.data.txt and leach.energy.txt (maybe just the entire folder) and the leach-c results, I juss want to reconcile my results and compare graphs

Last edited by wellytg; 05-08-2015 at 09:22 AM. Reason: wrong wording
 
Old 05-08-2015, 02:59 PM   #87
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Re #86.

The latest leach, leach-c results are from PCLinuxOS 2012.08 :
`leach_sims__pclos2012.08.tar.gz'
https://drive.google.com/file/d/0B7S...ew?usp=sharing

The best results with a temporary OS are from PCLinuxOS 2013.* :
See the other leach+pegasis posts ...
http://www.linuxquestions.org/questions/tags/pegasis/
( I can upload a similar "package-2013" ... later.)


-
 
Old 05-15-2015, 12:24 PM   #88
emprit
Member
 
Registered: Feb 2015
Location: jl. bogor 1 no 91, malang, jawa timur, indonesia
Distribution: any linux
Posts: 81

Rep: Reputation: Disabled
sir knudfl, can i get output about delay, throughput on leach-c?
 
Old 06-13-2015, 11:18 PM   #89
arifmahmudi
LQ Newbie
 
Registered: Mar 2015
Posts: 6

Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post

No script ns-2.34/test ?
When you do 1) $ cd ns-allinone-2.34/
2) $ tar xvf leach+pegasis-ns234-files-2.tar.gz
... then you will get ns-2.34/{ test, leach_test, mit/ }.

-
<-- 18#
sir, knudfl
what the differennt "leach_test" and "test"?
 
  


Reply

Tags
leach, leach-ex#4, ns2



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
problem with running leach protocol in ns2.34 leach.er Mohamed69 Linux - Software 14 04-16-2018 07:10 AM
leach.out total energy increase leach ns2.34 linuxUser123linux Linux - Software 1 07-13-2013 04:54 AM
Differences between LEACH results on ns2.1b5 and ns2.35 deepa_2111 Linux - Software 15 05-16-2013 05:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking > Linux - Wireless Networking

All times are GMT -5. The time now is 02:41 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration