More functions to the toplevel
It would be useful to have more functions available to the interactive mode / toplevel:
- compile to simulation package
- change plot period
As this mode is intended for exploratory simulations, one may not know what is a meaningful plotting period. And when simulation initialization is costly, having the option to dump a simulation package would reduce the time spent (re)initializing.
Adding to the list from #586
- Have the capacity to
%mod: alarm [T>10] do $SNAPSHOT ; repeat [true]from the toplevel
How do you preserve this in the inputs.ka file if some arbitrary time has passed you say? Great question! How about adding the event number as a condition to the boolean conditioner of the precondition? I.e.
//%mod: alarm [T]>10 do $SNAPSHOT ; repeat [true]
%mod: alarm ([T]>10 && [E] > 563) do $SNAPSHOT ; repeat [true]
Where the first line is what the user wrote at the toplevel, when paused at say event number 563, and the second line is what actually happened.