LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 09-09-2013, 03:56 PM   #1
ines8989
Member
 
Registered: Mar 2013
Posts: 62

Rep: Reputation: Disabled
Trace for energy Model in ns2.31


Hi , can anyone help me with the signification of the fields in the trace file of energy model in ns2 that i have simulated with TCP protocol.
Here is extracted some line of the trace file obtained .
please help me.Thanks
Code:
s 10.000000000 _1_ AGT  --- 15 tcp 40 [0 0 0 0] [energy 49.995780 ei 0.000 es 0.000 et 0.001 er 0.004] ------- [1:0 3:0 32 0] [0 0] 0 0
r 10.000000000 _1_ RTR  --- 15 tcp 40 [0 0 0 0] [energy 49.995780 ei 0.000 es 0.000 et 0.001 er 0.004] ------- [1:0 3:0 32 0] [0 0] 0 0
s 12.041819866 _7_ RTR  --- 21 message 32 [0 0 0 0] [energy 49.995780 ei 0.000 es 0.000 et 0.001 er 0.004] ------- [7:255 -1:255 32 0] 
N -t 12.042335 -n 4 -e 49.995514
N -t 12.042335 -n 13 -e 49.995514
N -t 12.042335 -n 10 -e 49.995514
N -t 12.042335 -n 9 -e 49.995514
N -t 12.042335 -n 0 -e 49.995514
N -t 12.042336 -n 1 -e 49.995514
I did'nt inderstand especially the -n what it refers and the values after -e .
 
Old 01-30-2014, 04:31 AM   #2
Aska123
Member
 
Registered: Apr 2013
Posts: 197

Rep: Reputation: Disabled
- e is remaining energy of node

Do not know about -n
-e 49.995514 is remaining energy of node at time 12.042335.

Last edited by Aska123; 01-30-2014 at 04:33 AM.
 
Old 01-30-2014, 04:43 AM   #3
ines8989
Member
 
Registered: Mar 2013
Posts: 62

Original Poster
Rep: Reputation: Disabled
Trace for energy Model in ns2.31

Thank you verry much Aska123 for your reply
 
Old 01-30-2014, 05:07 AM   #4
Aska123
Member
 
Registered: Apr 2013
Posts: 197

Rep: Reputation: Disabled
Do you have any awk script to calculate remaining energy of nodes ?
 
Old 01-30-2014, 05:28 AM   #5
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
The script "energy.awk" says "remaining_energy = energy;" in line 41.

→ awk_scripts_11.2013.tar.bz2
https://drive.google.com/file/d/0B7S...it?usp=sharing
-
Attached Files
File Type: txt energy.awk.txt (455 Bytes, 237 views)

Last edited by knudfl; 01-30-2014 at 05:31 AM.
 
Old 01-30-2014, 11:13 AM   #6
Aska123
Member
 
Registered: Apr 2013
Posts: 197

Rep: Reputation: Disabled
Dear Knudfi
Thanks for reply.

The script energy.awk is showing nothing in its output.
I run it as follows
awk -f energy.awk MyTest.tr > energy.dat

Mytest.tr is a trace file. which contains only two nodes 0 and 1
so I changed in energy.awk nodeid =_1_

I am attaching tr file .
Please reply
Attached Files
File Type: txt Mytest.tr.txt (124.1 KB, 121 views)
 
  


Reply

Tags
awk-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
NS2: LEACH Energy Error... Nimat Ullah Linux - Software 0 06-02-2013 10:44 PM
NS2: Problem with Traffic model generator VANET (static traffic model generator for ns2) Anil Kumar Giri Linux - Software 0 04-28-2013 08:48 PM
ns2 segmentation fault when using energy model edsionwang Programming 0 04-27-2013 05:45 PM
Sir, While installing ns2.34 on fedora 16 got the error : trace/cmu-trace.cc 1327:22 jeevanpinto Linux - Newbie 2 06-28-2012 03:35 AM
energy metric in ns2 roh Linux - Networking 2 01-13-2010 02:48 AM

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

All times are GMT -5. The time now is 09:36 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