Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/ensemble/ensemble_solutions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ function EnsembleSolution(sim::T, elapsedTime,
typeof(sim)}(sim, elapsedTime, converged)
end

Base.reverse(sim::EnsembleSolution) = EnsembleSolution(reverse(sim.u), sim.elapsedTime, sim.converged)
function Base.reverse(sim::EnsembleSolution)
EnsembleSolution(reverse(sim.u), sim.elapsedTime, sim.converged)
end

"""
$(TYPEDEF)
Expand Down
2 changes: 1 addition & 1 deletion src/problems/problem_utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -179,4 +179,4 @@ function Base.summary(io::IO, prob::AbstractPDEProblem)
no_color)
end

Base.copy(p::SciMLBase.NullParameters) = p
Base.copy(p::SciMLBase.NullParameters) = p
13 changes: 9 additions & 4 deletions src/solutions/ode_solutions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ https://docs.sciml.ai/DiffEqDocs/stable/basics/solution/
[the return code documentation](https://docs.sciml.ai/SciMLBase/stable/interfaces/Solutions/#retcodes).
"""
struct ODESolution{T, N, uType, uType2, DType, tType, rateType, P, A, IType, S,
AC <: Union{Nothing, Vector{Int}}} <:
AC <: Union{Nothing, Vector{Int}}, SSS} <:
AbstractODESolution{T, N, uType}
u::uType
u_analytic::uType2
Expand All @@ -42,6 +42,7 @@ struct ODESolution{T, N, uType, uType2, DType, tType, rateType, P, A, IType, S,
stats::S
alg_choice::AC
retcode::ReturnCode.T
subsolutions::SSS
end

Base.@propagate_inbounds function Base.getproperty(x::AbstractODESolution, s::Symbol)
Expand All @@ -53,12 +54,16 @@ Base.@propagate_inbounds function Base.getproperty(x::AbstractODESolution, s::Sy
end

function ODESolution{T, N}(u, u_analytic, errors, t, k, prob, alg, interp, dense,
tslocation, stats, alg_choice, retcode) where {T, N}
tslocation, stats, alg_choice, retcode,
subsolutions = nothing) where {T, N}
return ODESolution{T, N, typeof(u), typeof(u_analytic), typeof(errors), typeof(t),
typeof(k), typeof(prob), typeof(alg), typeof(interp),
typeof(stats),
typeof(alg_choice)}(u, u_analytic, errors, t, k, prob, alg, interp,
dense, tslocation, stats, alg_choice, retcode)
typeof(alg_choice), typeof(subsolutions)}(u, u_analytic, errors, t,
k, prob, alg, interp,
dense, tslocation, stats,
alg_choice, retcode,
subsolutions)
end

function (sol::AbstractODESolution)(t, ::Type{deriv} = Val{0}; idxs = nothing,
Expand Down
2 changes: 1 addition & 1 deletion src/solutions/pde_solutions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ struct PDENoTimeSolution{T, N, uType, Disc, Sol, domType, ivType, dvType, P, A,
retcode::ReturnCode.T
stats::S
end

TruncatedStacktraces.@truncate_stacktrace PDENoTimeSolution 1 2

const PDESolution{T, N, S, D} = Union{PDETimeSeriesSolution{T, N, S, D},
Expand Down