File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed
Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 11name = " DynamicalSystemsBase"
22uuid = " 6e36e845-645a-534a-86f2-f5d4aa5a06b4"
33repo = " https://github.com/JuliaDynamics/DynamicalSystemsBase.jl.git"
4- version = " 3.11.1 "
4+ version = " 3.11.2 "
55
66[deps ]
77ForwardDiff = " f6369f11-7733-5829-9624-2563aa707210"
Original file line number Diff line number Diff line change @@ -332,7 +332,7 @@ StateSpaceSets.dimension(ds::DynamicalSystem) = length(current_state(ds))
332332# API - altering status of the system
333333# ##########################################################################################
334334"""
335- set_state!(ds::DynamicalSystem, u::AbstractArray{Real})
335+ set_state!(ds::DynamicalSystem, u::AbstractArray{<: Real})
336336
337337Set the state of `ds` to `u`, which must match dimensionality with that of `ds`.
338338Also ensure that the change is notified to whatever integration protocol is used.
383383 set_state!(ds::DynamicalSystem, mapping::AbstractDict)
384384
385385Convenience version of `set_state!` that iteratively calls `set_state!(ds, val, i)`
386- for all index-value pairs `(i, val)` in `mapping`. This allows you to
387- partially set only some state variables.
386+ for all index-value pairs `(i, val)` in `mapping`.
387+ This is useful primarily in two cases:
388+ 1) to partially set only some state variables,
389+ 2) to set variables by name (if the system is created via ModelingToolkit.jl)
390+ so that you don't have to keep track of the order of the dynamic variables.
388391"""
389392function set_state! (ds:: DynamicalSystem , mapping:: AbstractDict )
390393 # ensure we use a mutable vector, so same code works for in-place problems
You can’t perform that action at this time.
0 commit comments