diff --git a/src/DormandPrince.jl b/src/DormandPrince.jl index 1646237..92056a3 100644 --- a/src/DormandPrince.jl +++ b/src/DormandPrince.jl @@ -7,7 +7,8 @@ include("types.jl") include("interface.jl") include("dp5_impl/mod.jl") -using DormandPrince.DP5Impl: dp5_integrate + +using DormandPrince.DP5Impl: core_integrator # export Interface export DP5Solver, integrate diff --git a/src/dp5_impl/mod.jl b/src/dp5_impl/mod.jl index cb193b9..1091ff6 100644 --- a/src/dp5_impl/mod.jl +++ b/src/dp5_impl/mod.jl @@ -1,13 +1,9 @@ module DP5Impl using ..DormandPrince: DormandPrince, DP5Solver, Vars, Consts, Options, Report -# external imports include("helpers.jl") include("checks.jl") include("solver.jl") -export DP5Solver, dp5_integrate - - end \ No newline at end of file diff --git a/src/dp5_impl/solver.jl b/src/dp5_impl/solver.jl index f84ba33..b70fead 100644 --- a/src/dp5_impl/solver.jl +++ b/src/dp5_impl/solver.jl @@ -3,10 +3,10 @@ #include("checks.jl") #include("helpers.jl") -function dp5_integrate( - solver, - xend -) +function core_integrator( + solver::DP5Solver{T}, + xend::T +) where {T <: Real} # check nmax, uround, safety factor, beta, safety_factor # just accept solver.options and handle accessing attributes internally diff --git a/src/interface.jl b/src/interface.jl index e8e5285..cebbf7f 100644 --- a/src/interface.jl +++ b/src/interface.jl @@ -29,7 +29,7 @@ end # 2. integrate(solver, times) -> iterator # 3. integrate(callback, solver, times) -> vector of states with callback applied -integrate(solver::AbstractDPSolver{T}, time::T) where {T<:Real} = dp5_integrate(solver, time) +integrate(solver::AbstractDPSolver{T}, time::T) where {T <: Real} = core_integrator(solver, time) integrate(solver::AbstractDPSolver{T}, times::AbstractVector{T}) where {T <: Real} = DP5Iterator(solver, times) function integrate(callback, solver::AbstractDPSolver{T}, times::AbstractVector{T}; sort_times::Bool = true) where {T <: Real}