From da185b02c6bbef7f16c60edb8421cdf7610c329c Mon Sep 17 00:00:00 2001 From: David Widmann Date: Thu, 22 Feb 2024 17:07:52 +0100 Subject: [PATCH] Remove DDEStats --- src/DelayDiffEq.jl | 1 - src/ddestats.jl | 34 ---------------------------------- src/solve.jl | 3 +-- 3 files changed, 1 insertion(+), 37 deletions(-) delete mode 100644 src/ddestats.jl diff --git a/src/DelayDiffEq.jl b/src/DelayDiffEq.jl index d360675e..f4f99c30 100644 --- a/src/DelayDiffEq.jl +++ b/src/DelayDiffEq.jl @@ -35,7 +35,6 @@ export Discontinuity, MethodOfSteps include("discontinuity_type.jl") include("functionwrapper.jl") -include("ddestats.jl") include("integrators/type.jl") include("integrators/utils.jl") diff --git a/src/ddestats.jl b/src/ddestats.jl deleted file mode 100644 index 421376d0..00000000 --- a/src/ddestats.jl +++ /dev/null @@ -1,34 +0,0 @@ -mutable struct DDEStats - nf::Int - nf2::Int - nw::Int - nsolve::Int - njacs::Int - nnonliniter::Int - nnonlinconvfail::Int - nfpiter::Int - nfpconvfail::Int - ncondition::Int - naccept::Int - nreject::Int - maxeig::Float64 -end - -DDEStats(x::Int = -1) = DDEStats(x, x, x, x, x, x, x, x, x, x, x, x, 0.0) - -function Base.show(io::IO, s::DDEStats) - println(io, summary(s)) - @printf io "%-60s %-d\n" "Number of function 1 evaluations:" s.nf - @printf io "%-60s %-d\n" "Number of function 2 evaluations:" s.nf2 - @printf io "%-60s %-d\n" "Number of W matrix evaluations:" s.nw - @printf io "%-60s %-d\n" "Number of linear solves:" s.nsolve - @printf io "%-60s %-d\n" "Number of Jacobians created:" s.njacs - @printf io "%-60s %-d\n" "Number of nonlinear solver iterations:" s.nnonliniter - @printf io "%-60s %-d\n" "Number of nonlinear solver convergence failures:" s.nnonlinconvfail - @printf io "%-60s %-d\n" "Number of fixed-point solver iterations:" s.nfpiter - @printf io "%-60s %-d\n" "Number of fixed-point solver convergence failures:" s.nfpconvfail - @printf io "%-60s %-d\n" "Number of rootfind condition calls:" s.ncondition - @printf io "%-60s %-d\n" "Number of accepted steps:" s.naccept - @printf io "%-60s %-d" "Number of rejected steps:" s.nreject - iszero(s.maxeig) || @printf io "\n%-60s %-d" "Maximum eigenvalue recorded:" s.maxeig -end diff --git a/src/solve.jl b/src/solve.jl index c6a145fe..7a1e938c 100644 --- a/src/solve.jl +++ b/src/solve.jl @@ -166,8 +166,7 @@ function DiffEqBase.__init(prob::DiffEqBase.AbstractDDEProblem, Val(isinplace(prob))) # separate statistics of the integrator and the history - #stats = DDEStats(0) - stats = SciMLBase.DEStats(0) + stats = SciMLBase.DEStats(0) # create solution alg_choice = iscomposite(alg) ? Int[] : nothing