Hi,
I want to *add some users to the example* (the attached file), in order to
simulate congestion in the network.
 I added one tcp and one udp users like this:

set n0 [$ns node]
set n1 [$ns node]
set n2 [$ns node]
set n3 [$ns node]

$ns duplex-link $n0 $n2 2Mb 10ms DropTail
$ns duplex-link $n1 $n2 2Mb 10ms DropTail
$ns duplex-link $n2 $n3 1.7Mb 20ms DropTail

set tcp [new Agent/TCP]
$tcp set class_ 2
$ns attach-agent $n0 $tcp
set sink [new Agent/TCPSink]
$ns attach-agent $n3 $sink
$ns connect $tcp $sink
$tcp set fid_ 1

set udp [new Agent/UDP]
$ns attach-agent $n1 $udp
set null [new Agent/Null]
$ns attach-agent $n3 $null
$ns connect $udp $null
$udp set fid_ 2

$ns at 0.1 "$udp start"
$ns at 1.0 "$tcp start"
$ns at 4.0 "$tcp stop"
$ns at 4.5 "$udp stop"

1. Is that the way to add users?
2. if I want to add another one, how much nodes I need to add, and how is
the best way to link them?
3. do I need to add queue?

Reply via email to