Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Default algorithm choises requires DifferentialEquations.jl" after using DifferentialEquations #907

Closed
albheim opened this issue Oct 11, 2022 · 0 comments · Fixed by #909

Comments

@albheim
Copy link

albheim commented Oct 11, 2022

Something is not working as intended here it seems.

julia> using DifferentialEquations

julia> f(x, p, t) = sin(t) .- x
f (generic function with 1 method)

julia> prob = ODEProblem(f, [1.0], (0, 10))
ODEProblem with uType Vector{Float64} and tType Int64. In-place: false
timespan: (0, 10)
u0: 1-element Vector{Float64}:
 1.0

julia> init(prob)
ERROR: Default algorithm choices require DifferentialEquations.jl.
Please specify an algorithm (e.g., `solve(prob, Tsit5())` or
`init(prob, Tsit5())` for an ODE) or import DifferentialEquations
directly.

You can find the list of available solvers at https://diffeq.sciml.ai/stable/solvers/ode_solve/
and its associated pages.

Stacktrace:
   [1-8]  internal
       @ DiffEqBase
     [9] init(::ODEProblem{Vector{Float64}, Tuple{Int64, Int64}, …})
       @ DiffEqBase ~/.julia/packages/DiffEqBase/5U1Mr/src/solve.jl:393
Use `err` to retrieve the full stack trace.

julia> solve(prob)
retcode: Success
Interpolation: specialized 4th order "free" interpolation, specialized 2nd order "free" stiffness-aware interpolation
t: 18-element Vector{Float64}:
  0.0
  0.08707260550141684
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant