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

Re: [ns] Event scheduling



>Dear NS users,
>
>(I'm not sure if I have sent it two times, I'm
>sorry if I have.)
>
>If at time 0, I used the command "$ns at $r proc"
>to schedule an event that happens
>at time $r, how can I make the event happen earlier
>than $r? I mean, after I schedule the event, I
>want the event to happen at $x (0 < $x < $r), how
>can I realize this?
>
>Your help will be greatly appreciated!
>
>S. Wu
------------------------------------------------------------------

Dear Wu,
    in ns u can schedule an event at a certain time and then later in the
code schedule it to happen in any time earlier,
provided that there is NO conflict (eg u can start a traffic agent then
start the same agent in an earlier moment BUT u have to stop the agent
before it is restarted later in time. If it is something that happens
instantly -eg printing some statistics- ns will do the events in time order
even if the one event appears before an other in the code). In this case ns
can take all events and do them in the right time order. Of course, you have
to define the values of x and r before u use the scheduler. I hope that I
understood your question,

all the best,
------------------------------------------------------
Sarafidis Iordanis
------------------------------------------------------