Class Event
Defined in File event.h
Class Documentation
-
class Event
The Event class.
Represents an event. I.e., a potential discontinuity in the state or state derivative that occurs when some trigger function transitions from
falsetotrue.This will be extended to represent trigger time, trigger persistence, event assignment priority, and other properties of the respective event trigger and event assignments.
Public Functions
-
inline Event(std::string id, bool use_values_from_trigger_time, bool initial_value, realtype priority)
Event constructor.
- Parameters:
id – ID of the event
use_values_from_trigger_time – Whether the event assignment is evaluated using the state from the time point at which the event triggered (true), or at the time point at which the event assignment is evaluated (False).
initial_value – Initial value of the root function
priority – Priority of the event assignments
-
inline std::string const &get_id() const
Get the ID of the event.
- Returns:
The ID of the event.
-
inline bool get_initial_value() const
Get the initial value of the root function.
- Returns:
The value of the root function at t_0.
-
inline realtype get_priority() const
Get the priority of the event assignments.
- Returns:
The priority of the event assignments, or NAN if undefined.
-
inline bool uses_values_from_trigger_time() const
Check if the event assignment is evaluated using the state from the time point at which the event is triggered or executed.
- Returns:
True if the event assignment is evaluated using the state from the time point at which the event triggered, false otherwise.
-
inline Event(std::string id, bool use_values_from_trigger_time, bool initial_value, realtype priority)