Public API
This page lists exported symbols of CTModels.OCP.
From CTModels.OCP
time_dependence!
CTModels.OCP.time_dependence! — Function
time_dependence!(ocp::CTModels.OCP.PreModel; autonomous)
Set the time dependence of the optimal control problem ocp.
Arguments
ocp::PreModel: The optimal control problem being defined.autonomous::Bool: Indicates whether the system is autonomous (true) or time-dependent (false).
Preconditions
- The time dependence must not have been set previously.
Behavior
This function sets the autonomous field of the model to indicate whether the system's dynamics explicitly depend on time. It can only be called once.
Errors
Throws Exceptions.PreconditionError if the time dependence has already been set.
Example
julia> ocp = PreModel(...)
julia> time_dependence!(ocp; autonomous=true)