sourcecommand in "Loading commands from a file" on page 3-13), use the commands in this section to run the simulation.
3.6.1 Creating a schedule
schedule command generates and returns the schedule (the order in which stars are invoked). For domains such as DE, this command returns a not-implemented message (since there is no "compile time" DE schedule as there is for SDF). The syntax is:
3.6.2 Running the simulation
run command generates the schedule and runs it n times, where n is the argument (the argument may be omitted; its default value is 1). For the DE interpreter, this command runs the simulation for n time units, and n may be a floating point number (default 1.0). If this command is repeated, the simulation is started from the beginning. If animation is enabled, the full name of each star will be printed to the standard output when the star fires. The syntax is:
3.6.3 Continuing a simulation
cont command continues the simulation for n additional steps, or time units. If the argument is omitted, the default value of the argument is the value of the last argument given to a
cont command (1.0 if no argument was ever given). The syntax is
3.6.4 Wrapping up a simulation
wrapup command calls the wrapup method of the current target (which, as a rule, will call the
wrapup method of each star), signaling the end of the simulation run. The syntax is
3.6.5 Interrupting a simulation
requests a halt of the currently executing simulation. Note that the halt does not occur immediately. This merely registers the request with the scheduler. This is especially useful within Tcl stars.
3.6.6 Obtaining the stop time of the current run
returns the time until which the current simulation will run. Tcl/Tk stars can use this command in their setup or go methods to find out the stop time of the current run.
3.6.7 Obtaining time information from the scheduler
returns the current time from the top-level scheduler of the current universe. If the target has a parameter named "schedulePeriod", then the returned time is divided by this value. The command
returns the scheduler time without dividing by "schedulePeriod."
schedtime actual should return the number of iterations. In SDF, "schedulePeriod" is usually set to 0, since in SDF has no notion of time, and to a timed domain, such as DE, SDF universes appear to fire instantaneously.
3.6.8 Animating a simulation
animation command can be used to display on the standard output the name of each star as it runs. The syntax
enables animation, while
disables it. The syntax
simply tells you whether animation is enabled or disabled.