The following is a summary of the scripting methods available either in MATLAB through the ArtisynthHandle object, or in Jython as built-in console functions:
Returns the ArtiSynth Main object.
Loads the named model along with optional arguments. name is either the fully-qualified classname of the model’s RootModel, or one of the shorter names that appears under the ArtiSynth Models menu, and args... is an optional variable-length list of string arguments that are used to form the args argument of the model’s build() method. Currently, if ArtiSynth is being run in batch mode (Section 3.3), then the Models menu is not created and so it is necessary to use the fully qualified classname.
Loads a model from an ArtiSynth file. filename is a string giving the file’s path.
Save a model to an ArtiSynth file.
Save a model to an ArtiSynth file. The options saveWayPointData and coreCompsOnly specify whether to (a) save waypoint data, and (b) save only components from artisynth_core.
Starts the simulation running.
Starts and runs the simulation for t seconds.
Pauses the simulation.
Single steps the simulation.
Resets the simulation to time 0.
Forwards the simulation to the next waypoint.
Rewinds the simulation to the last waypoint.
Delays execution for t seconds. In MATLAB, the same effect can be achieved using the MATLAB command pause(t).
Blocks until the simulation has completed.
Returns true if simulation is still running.
Returns current ArtiSynth simulation time in seconds.
Reloads the current model.
Adds a simulation waypoint at time t, where t is a floating point value giving the time in seconds.
Adds a breakpoint at time t.
Removes any waypoint or breakpoint at time t.
Removes all waypoints and breakpoints.
Save waypoints and their data to a specified file
Load waypoints and their data from a specified file
Returns the current RootModel.
Finds a component defined by path with respect to the current RootModel.
Returns the current ArtiSynth selection list.
Returns the i-th selection list item (1-based for MATLAB; 0-based for Jython).