Skip to content

Commit 50815f5

Browse files
Merge pull request #1712 from SciML/docstrings
fix some more docstrings
2 parents 08fc405 + 5ec69f3 commit 50815f5

File tree

6 files changed

+35
-32
lines changed

6 files changed

+35
-32
lines changed

docs/src/systems/JumpSystem.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ structural_simplify
2424
## Problem Constructors
2525

2626
```@docs
27-
DiscreteProblem(::JumpSystem,args...)
28-
JumpProblem(::JumpSystem,args...)
27+
SciMLBase.DiscreteProblem(sys::JumpSystem,args...)
28+
JumpProcesses.JumpProblem(sys::JumpSystem,args...)
2929
```

src/ModelingToolkit.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,12 @@ export AbstractTimeDependentSystem, AbstractTimeIndependentSystem,
160160
AbstractMultivariateSystem
161161
export ODESystem, ODEFunction, ODEFunctionExpr, ODEProblemExpr, convert_system
162162
export DAEFunctionExpr, DAEProblemExpr
163-
export SDESystem, SDEFunction, SDEFunctionExpr, SDESystemExpr
163+
export SDESystem, SDEFunction, SDEFunctionExpr, SDEProblemExpr
164164
export SystemStructure
165165
export JumpSystem
166166
export ODEProblem, SDEProblem
167-
export NonlinearProblem, NonlinearProblemExpr
167+
export NonlinearFunction, NonlinearFunctionExpr
168+
export NonlinearProblem, BlockNonlinearProblem, NonlinearProblemExpr
168169
export OptimizationProblem, OptimizationProblemExpr
169170
export AutoModelingToolkit
170171
export SteadyStateProblem, SteadyStateProblemExpr

src/structural_transformation/codegen.jl

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -484,10 +484,6 @@ function build_observed_function(state, ts, var_eq_matching, var_sccs,
484484
expression ? ex : @RuntimeGeneratedFunction(ex)
485485
end
486486

487-
struct ODAEProblem{iip} end
488-
489-
ODAEProblem(args...; kw...) = ODAEProblem{true}(args...; kw...)
490-
491487
"""
492488
ODAEProblem{iip}(sys, u0map, tspan, parammap = DiffEqBase.NullParameters(); kw...)
493489
@@ -497,9 +493,15 @@ already been applied to them.
497493
In these cases, the constructor uses the knowledge of the strongly connected
498494
components calculated during the process of simplification as the basis for
499495
building pre-simplified nonlinear systems in the implicit solving.
496+
500497
In summary: these problems are structurally modified, but could be
501-
more efficient and more stable. Note, the returned object is still of type [`ODEProblem`](@ref).
498+
more efficient and more stable. Note, the returned object is still of type
499+
[`ODEProblem`](@ref).
502500
"""
501+
struct ODAEProblem{iip} end
502+
503+
ODAEProblem(args...; kw...) = ODAEProblem{true}(args...; kw...)
504+
503505
function ODAEProblem{iip}(sys,
504506
u0map,
505507
tspan,

src/systems/diffeqs/abstractodesystem.jl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -657,7 +657,7 @@ function DiffEqBase.DAEProblem{iip}(sys::AbstractODESystem,du0map,u0map,tspan,
657657
kwargs...) where iip
658658
```
659659
660-
Generates an DAEProblem from an ODESystem and allows for automatically
660+
Generates a DAEProblem from an ODESystem and allows for automatically
661661
symbolically calculating numerical enhancements.
662662
"""
663663
function DiffEqBase.DAEProblem(sys::AbstractODESystem, args...; kwargs...)
@@ -742,7 +742,7 @@ function DAEProblemExpr{iip}(sys::AbstractODESystem,u0map,tspan,
742742
kwargs...) where iip
743743
```
744744
745-
Generates a Julia expression for constructing an ODEProblem from an
745+
Generates a Julia expression for constructing a DAEProblem from an
746746
ODESystem and allows for automatically symbolically calculating
747747
numerical enhancements.
748748
"""
@@ -780,7 +780,7 @@ end
780780

781781
"""
782782
```julia
783-
function DiffEqBase.SteadyStateProblem(sys::AbstractODESystem,u0map,
783+
function SciMLBase.SteadyStateProblem(sys::AbstractODESystem,u0map,
784784
parammap=DiffEqBase.NullParameters();
785785
version = nothing, tgrad=false,
786786
jac = false,
@@ -791,12 +791,12 @@ function DiffEqBase.SteadyStateProblem(sys::AbstractODESystem,u0map,
791791
Generates an SteadyStateProblem from an ODESystem and allows for automatically
792792
symbolically calculating numerical enhancements.
793793
"""
794-
function DiffEqBase.SteadyStateProblem(sys::AbstractODESystem, args...; kwargs...)
794+
function SciMLBase.SteadyStateProblem(sys::AbstractODESystem, args...; kwargs...)
795795
SteadyStateProblem{true}(sys, args...; kwargs...)
796796
end
797797

798798
function DiffEqBase.SteadyStateProblem{iip}(sys::AbstractODESystem, u0map,
799-
parammap = DiffEqBase.NullParameters();
799+
parammap = SciMLBase.NullParameters();
800800
check_length = true, kwargs...) where {iip}
801801
f, u0, p = process_DEProblem(ODEFunction{iip}, sys, u0map, parammap;
802802
steady_state = true,
@@ -807,7 +807,7 @@ end
807807

808808
"""
809809
```julia
810-
function DiffEqBase.SteadyStateProblemExpr(sys::AbstractODESystem,u0map,
810+
function SciMLBase.SteadyStateProblemExpr(sys::AbstractODESystem,u0map,
811811
parammap=DiffEqBase.NullParameters();
812812
version = nothing, tgrad=false,
813813
jac = false,
@@ -823,7 +823,7 @@ numerical enhancements.
823823
struct SteadyStateProblemExpr{iip} end
824824

825825
function SteadyStateProblemExpr{iip}(sys::AbstractODESystem, u0map,
826-
parammap = DiffEqBase.NullParameters();
826+
parammap = SciMLBase.NullParameters();
827827
check_length = true,
828828
kwargs...) where {iip}
829829
f, u0, p = process_DEProblem(ODEFunctionExpr{iip}, sys, u0map, parammap;

src/systems/discrete_system/discrete_system.jl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -172,12 +172,12 @@ end
172172
173173
Generates an DiscreteProblem from an DiscreteSystem.
174174
"""
175-
function DiffEqBase.DiscreteProblem(sys::DiscreteSystem, u0map, tspan,
176-
parammap = DiffEqBase.NullParameters();
177-
eval_module = @__MODULE__,
178-
eval_expression = true,
179-
use_union = false,
180-
kwargs...)
175+
function SciMLBase.DiscreteProblem(sys::DiscreteSystem, u0map, tspan,
176+
parammap = SciMLBase.NullParameters();
177+
eval_module = @__MODULE__,
178+
eval_expression = true,
179+
use_union = false,
180+
kwargs...)
181181
dvs = states(sys)
182182
ps = parameters(sys)
183183
eqs = equations(sys)

src/systems/nonlinear/nonlinearsystem.jl

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ end
183183

184184
"""
185185
```julia
186-
function DiffEqBase.NonlinearFunction{iip}(sys::NonlinearSystem, dvs = states(sys),
186+
function SciMLBase.NonlinearFunction{iip}(sys::NonlinearSystem, dvs = states(sys),
187187
ps = parameters(sys);
188188
version = nothing,
189189
jac = false,
@@ -195,17 +195,17 @@ Create an `NonlinearFunction` from the [`NonlinearSystem`](@ref). The arguments
195195
`dvs` and `ps` are used to set the order of the dependent variable and parameter
196196
vectors, respectively.
197197
"""
198-
function DiffEqBase.NonlinearFunction(sys::NonlinearSystem, args...; kwargs...)
198+
function SciMLBase.NonlinearFunction(sys::NonlinearSystem, args...; kwargs...)
199199
NonlinearFunction{true}(sys, args...; kwargs...)
200200
end
201201

202-
function DiffEqBase.NonlinearFunction{iip}(sys::NonlinearSystem, dvs = states(sys),
203-
ps = parameters(sys), u0 = nothing;
204-
version = nothing,
205-
jac = false,
206-
eval_expression = true,
207-
sparse = false, simplify = false,
208-
kwargs...) where {iip}
202+
function SciMLBase.NonlinearFunction{iip}(sys::NonlinearSystem, dvs = states(sys),
203+
ps = parameters(sys), u0 = nothing;
204+
version = nothing,
205+
jac = false,
206+
eval_expression = true,
207+
sparse = false, simplify = false,
208+
kwargs...) where {iip}
209209
f_gen = generate_function(sys, dvs, ps; expression = Val{eval_expression}, kwargs...)
210210
f_oop, f_iip = eval_expression ? (@RuntimeGeneratedFunction(ex) for ex in f_gen) : f_gen
211211
f(u, p) = f_oop(u, p)
@@ -242,7 +242,7 @@ end
242242

243243
"""
244244
```julia
245-
function DiffEqBase.NonlinearFunctionExpr{iip}(sys::NonlinearSystem, dvs = states(sys),
245+
function SciMLBase.NonlinearFunctionExpr{iip}(sys::NonlinearSystem, dvs = states(sys),
246246
ps = parameters(sys);
247247
version = nothing,
248248
jac = false,

0 commit comments

Comments
 (0)