[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: your mail



On Thu, 12 Aug 1999 10:43:54 PDT, Haobo Yu wrote: 
>> If I want to run the same simulation for many times, only changing some
>> parameters, but I want to write data to the same trace file, what should I
>> do? Is there any such example? 
>> 
>> I tried to use a single $ns for the whole simulation, but I am not sure if
>> it is possible. Also I am confused about "$ns run". Is there any parameter
>> for Simulator instproc run? The original code has no parameters defined, but
>> the NS notes and documents mentioned there are args.
>
>If you start and stop the simulation multiple times, although you can
>write to the same trace file, the result is a concatenation of all trace
>files, i.e., they are not continuous in time. 
>
>I think a better way is to build your simulation so that those different
>sims with different params actually co-exist in a single run of
>simulation. tcl/ex/rbp_demo.tcl is an example, where 3 different types of
>TCP streams are run on 3 parallel (and identical) topologies, but in the
>same run... 
>
>Of course doing postprocessing and combining traces there is always an
>option. 

Actually, rbp_demo.tcl outputs only one case at a time.  Output like
~nam/ex/rbp_demo.nam were made with postprocessing.

If you want to compare things in nam (like rbp_demo.nam), the
syncronize option is a better way to do that (now).

For the general problem of running a set of simulations sequentally or
in parallel, I recommend write your simulation to parse its arguments
($ARGV, rbp_demo.tcl does this OK) and then write a separate program
(in tcl or sh) to invoke the program in different ways.

   -John Heidemann