Advertisement
gvdr

Julia EachIndex Error

Jan 8th, 2018
725
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Julia 7.92 KB | None | 0 0
  1. ERROR: MethodError: no method matching eachindex(::Float64)
  2. Closest candidates are:
  3.   eachindex(::Cmd) at /home/gvdr/.julia/v0.6/Compat/src/Compat.jl:527
  4.   eachindex(::IndexLinear, ::AbstractArray) at abstractarray.jl:820
  5.   eachindex(::IndexLinear, ::AbstractArray, ::AbstractArray...) at abstractarray.jl:822
  6.   ...
  7. Stacktrace:
  8.  [1] modify_u!(::OrdinaryDiffEq.ODEIntegrator{OrdinaryDiffEq.Tsit5,Float64,Float64,Float64,Float64,Array{Float64,1},DiffEqBase.ODESolution{Float64,1,Array{Float64,1},Void,Void,Array{Float64,1},Array{Array{Float64,1},1},DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem},OrdinaryDiffEq.Tsit5,OrdinaryDiffEq.InterpolationData{#f,Array{Float64,1},Array{Float64,1},Array{Array{Float64,1},1},OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64}}},#f,Void,OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64},OrdinaryDiffEq.DEOptions{Float64,Float64,Float64,Float64,DiffEqBase.#ODE_DEFAULT_NORM,DiffEqBase.CallbackSet{Tuple{},Tuple{DiffEqBase.DiscreteCallback{DiffEqCallbacks.##21#22,DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void},DiffEqBase.#INITIALIZE_DEFAULT}}},DiffEqBase.#ODE_DEFAULT_ISOUTOFDOMAIN,DiffEqBase.#ODE_DEFAULT_PROG_MESSAGE,DiffEqBase.#ODE_DEFAULT_UNSTABLE_CHECK,DataStructures.BinaryHeap{Float64,DataStructures.LessThan},DataStructures.BinaryHeap{Float64,DataStructures.LessThan},Void,Void,Int64,Array{Float64,1},Array{Float64,1},Array{Float64,1}},Float64}, ::DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void}) at /home/gvdr/.julia/v0.6/DiffEqCallbacks/src/domain.jl:132
  9.  [2] affect!(::OrdinaryDiffEq.ODEIntegrator{OrdinaryDiffEq.Tsit5,Float64,Float64,Float64,Float64,Array{Float64,1},DiffEqBase.ODESolution{Float64,1,Array{Float64,1},Void,Void,Array{Float64,1},Array{Array{Float64,1},1},DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem},OrdinaryDiffEq.Tsit5,OrdinaryDiffEq.InterpolationData{#f,Array{Float64,1},Array{Float64,1},Array{Array{Float64,1},1},OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64}}},#f,Void,OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64},OrdinaryDiffEq.DEOptions{Float64,Float64,Float64,Float64,DiffEqBase.#ODE_DEFAULT_NORM,DiffEqBase.CallbackSet{Tuple{},Tuple{DiffEqBase.DiscreteCallback{DiffEqCallbacks.##21#22,DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void},DiffEqBase.#INITIALIZE_DEFAULT}}},DiffEqBase.#ODE_DEFAULT_ISOUTOFDOMAIN,DiffEqBase.#ODE_DEFAULT_PROG_MESSAGE,DiffEqBase.#ODE_DEFAULT_UNSTABLE_CHECK,DataStructures.BinaryHeap{Float64,DataStructures.LessThan},DataStructures.BinaryHeap{Float64,DataStructures.LessThan},Void,Void,Int64,Array{Float64,1},Array{Float64,1},Array{Float64,1}},Float64}, ::DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void}) at /home/gvdr/.julia/v0.6/DiffEqCallbacks/src/domain.jl:44
  10.  [3] apply_discrete_callback! at /home/gvdr/.julia/v0.6/OrdinaryDiffEq/src/callbacks.jl:186 [inlined]
  11.  [4] handle_callbacks!(::OrdinaryDiffEq.ODEIntegrator{OrdinaryDiffEq.Tsit5,Float64,Float64,Float64,Float64,Array{Float64,1},DiffEqBase.ODESolution{Float64,1,Array{Float64,1},Void,Void,Array{Float64,1},Array{Array{Float64,1},1},DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem},OrdinaryDiffEq.Tsit5,OrdinaryDiffEq.InterpolationData{#f,Array{Float64,1},Array{Float64,1},Array{Array{Float64,1},1},OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64}}},#f,Void,OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64},OrdinaryDiffEq.DEOptions{Float64,Float64,Float64,Float64,DiffEqBase.#ODE_DEFAULT_NORM,DiffEqBase.CallbackSet{Tuple{},Tuple{DiffEqBase.DiscreteCallback{DiffEqCallbacks.##21#22,DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void},DiffEqBase.#INITIALIZE_DEFAULT}}},DiffEqBase.#ODE_DEFAULT_ISOUTOFDOMAIN,DiffEqBase.#ODE_DEFAULT_PROG_MESSAGE,DiffEqBase.#ODE_DEFAULT_UNSTABLE_CHECK,DataStructures.BinaryHeap{Float64,DataStructures.LessThan},DataStructures.BinaryHeap{Float64,DataStructures.LessThan},Void,Void,Int64,Array{Float64,1},Array{Float64,1},Array{Float64,1}},Float64}) at /home/gvdr/.julia/v0.6/OrdinaryDiffEq/src/integrators/integrator_utils.jl:325
  12.  [5] loopfooter!(::OrdinaryDiffEq.ODEIntegrator{OrdinaryDiffEq.Tsit5,Float64,Float64,Float64,Float64,Array{Float64,1},DiffEqBase.ODESolution{Float64,1,Array{Float64,1},Void,Void,Array{Float64,1},Array{Array{Float64,1},1},DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem},OrdinaryDiffEq.Tsit5,OrdinaryDiffEq.InterpolationData{#f,Array{Float64,1},Array{Float64,1},Array{Array{Float64,1},1},OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64}}},#f,Void,OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64},OrdinaryDiffEq.DEOptions{Float64,Float64,Float64,Float64,DiffEqBase.#ODE_DEFAULT_NORM,DiffEqBase.CallbackSet{Tuple{},Tuple{DiffEqBase.DiscreteCallback{DiffEqCallbacks.##21#22,DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void},DiffEqBase.#INITIALIZE_DEFAULT}}},DiffEqBase.#ODE_DEFAULT_ISOUTOFDOMAIN,DiffEqBase.#ODE_DEFAULT_PROG_MESSAGE,DiffEqBase.#ODE_DEFAULT_UNSTABLE_CHECK,DataStructures.BinaryHeap{Float64,DataStructures.LessThan},DataStructures.BinaryHeap{Float64,DataStructures.LessThan},Void,Void,Int64,Array{Float64,1},Array{Float64,1},Array{Float64,1}},Float64}) at /home/gvdr/.julia/v0.6/OrdinaryDiffEq/src/integrators/integrator_utils.jl:288
  13.  [6] solve!(::OrdinaryDiffEq.ODEIntegrator{OrdinaryDiffEq.Tsit5,Float64,Float64,Float64,Float64,Array{Float64,1},DiffEqBase.ODESolution{Float64,1,Array{Float64,1},Void,Void,Array{Float64,1},Array{Array{Float64,1},1},DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem},OrdinaryDiffEq.Tsit5,OrdinaryDiffEq.InterpolationData{#f,Array{Float64,1},Array{Float64,1},Array{Array{Float64,1},1},OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64}}},#f,Void,OrdinaryDiffEq.Tsit5ConstantCache{Float64,Float64},OrdinaryDiffEq.DEOptions{Float64,Float64,Float64,Float64,DiffEqBase.#ODE_DEFAULT_NORM,DiffEqBase.CallbackSet{Tuple{},Tuple{DiffEqBase.DiscreteCallback{DiffEqCallbacks.##21#22,DiffEqCallbacks.PositiveDomainAffect{Void,Void,Void},DiffEqBase.#INITIALIZE_DEFAULT}}},DiffEqBase.#ODE_DEFAULT_ISOUTOFDOMAIN,DiffEqBase.#ODE_DEFAULT_PROG_MESSAGE,DiffEqBase.#ODE_DEFAULT_UNSTABLE_CHECK,DataStructures.BinaryHeap{Float64,DataStructures.LessThan},DataStructures.BinaryHeap{Float64,DataStructures.LessThan},Void,Void,Int64,Array{Float64,1},Array{Float64,1},Array{Float64,1}},Float64}) at /home/gvdr/.julia/v0.6/OrdinaryDiffEq/src/solve.jl:302
  14.  [7] #solve#1314(::Array{Any,1}, ::Function, ::DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem}, ::OrdinaryDiffEq.Tsit5, ::Array{Any,1}, ::Array{Any,1}, ::Array{Any,1}, ::Type{Val{true}}) at /home/gvdr/.julia/v0.6/OrdinaryDiffEq/src/solve.jl:7
  15.  [8] (::DiffEqBase.#kw##solve)(::Array{Any,1}, ::DiffEqBase.#solve, ::DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem}, ::OrdinaryDiffEq.Tsit5, ::Array{Any,1}, ::Array{Any,1}, ::Array{Any,1}, ::Type{Val{true}}) at ./<missing>:0 (repeats 2 times)
  16.  [9] #solve#2(::Bool, ::Array{Any,1}, ::Function, ::DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem}, ::Void) at /home/gvdr/.julia/v0.6/DifferentialEquations/src/default_solve.jl:14
  17.  [10] (::DiffEqBase.#kw##solve)(::Array{Any,1}, ::DiffEqBase.#solve, ::DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem}, ::Void) at ./<missing>:0
  18.  [11] #solve#1(::Bool, ::Array{Any,1}, ::Function, ::DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem}) at /home/gvdr/.julia/v0.6/DifferentialEquations/src/default_solve.jl:5
  19.  [12] (::DiffEqBase.#kw##solve)(::Array{Any,1}, ::DiffEqBase.#solve, ::DiffEqBase.ODEProblem{Float64,Float64,false,#f,Void,UniformScaling{Int64},DiffEqBase.StandardODEProblem}) at ./<missing>:0
  20.  [13] macro expansion at ./REPL.jl:97 [inlined]
  21.  [14] (::Base.REPL.##1#2{Base.REPL.REPLBackend})() at ./event.jl:73
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement