Skip to content

SimulationObject.simulate

SimulationObject.simulate(
    time_vector: List[double] = self.time_vector, 
    time_unit: str = self.time_unit, 
    state_values: List[double] = self.state_values, 
    derivative_values: List[double] = self.derivative_values, 
    parameter_values: List[double] = self.parameter_values, 
    reset: bool = False, 
    options: Dict[str, double] = self.options, 
    iterative: bool = True, 
    augment_time_vector: bool = True
) -> None

Runs simulation over the time points defined in time_vector in the SimulationObject object. Simulation results are stored in feature_data of the SimulationObject object.

Parameters

time_vector | time | t : List[double]
Any sequence of floats representing the time points to be simulated. Will be converted to a numpy.array and assigned to self.time_vector.
time_unit | tu : str
String representing the time unit of the simulation. Will be assigned to self.time_unit. Valid values for time units.
state_values | x0 : List[double]
Any sequence of floats representing initial state values for the simulation. Will be converted to a numpy.array and assigned to self.state_values.
derivative_values | xdot : List[double]
Any sequence of floats representing initial derivative values for the simulation. Only relevant for DAE models. Will be converted to a numpy.array and assigned to self.derivative_values.
parameter_values | theta | p : List[double]
Any sequence of floats representing parameter values for the simulation. Will be converted to a numpy.array and assigned to self.parameter_values.
reset : bool, default=False
If true, equivalent to running SimulationObject.reset_states prior to simulation.
options : Dict[str, double]
A Dict of options for the integrator. See simulation options for available options. Will be assigned to self.options.
iterative : bool, default=True
A flag for controlling whether to break up the simulation into several smaller simulations. Can improve simulation stability and required for proper functionality of activities.
augment_time_vector : bool, default=True
A flag for controlling whether to augment the time vector with additional time points during the simulation corresponding to when activities trigger. Can improve simulation stability.

Return type

None

Return value

None