About GT-ITM under the NS-2

來源:互聯網
上載者:User
There might not be much organized information about how to use GT-ITM in NS2, so I just put some notes here, just in case I forget how to use it.

GT-ITM would have been built in your NS2, you can check it by searching under NS2 home directory. To use it, you need do the following steps.
1. Create the specification file for GT-ITM.
2. Generate the topology file.
3. Convert to NS2 format.
4. Tweak the result.

1. The format of the specification file could be found in the README file under the gt-itm/docs directory. Or, you will find it by google. And it is as follows.

## Comments :
## <#method keyword> <#number of graphs> [<#initial seed>]
## <#stubs/xit> <#t-s edges> <#s-s edges>
## <#n> <#scale> <#edgemethod> <#alpha> [<#beta>] [<#gamma>]
## number of nodes = 1*8* (1 + 4*6) = 200
ts 10 47
4 0 0
1 20 3 1.0
8 20 3 0.8
6 10 3 0.5

Save the content to whatever, e.g. ts200.

2. To generate the topology, run 'itm ts200'
After running the itm command, you get the .gb files that are generated topoloy files.

3. To convert to whatever NS2 can use, run 'sgb2ns ts200-0.gb ts200.tcl'
Then you get .tcl files.

4. You would need to pay attention to what would be obsolete in the generated .tcl files.
For newer version of NS2, you would probabily need to modify the .tcl code generated by sg2ns a little bit to get it work.
The duplex-link-of-interfaces statement is somewhat obsolete, and you would need to change it to duplex-link to get the code work.

To use the .tcl code in NS2, you will need to source the code, and run it.

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.