From b7835cebf2d8a4ea2f929bb0c38d967a73c115a6 Mon Sep 17 00:00:00 2001 From: schillic Date: Fri, 1 Mar 2024 17:38:53 +0100 Subject: [PATCH 1/2] remove 'time' macro in comments --- src/Discretization/Exponentiation.jl | 4 ++-- test/models/hybrid/lotka_volterra.jl | 16 ++++++++-------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/Discretization/Exponentiation.jl b/src/Discretization/Exponentiation.jl index f22da26321..4af7e41e9f 100644 --- a/src/Discretization/Exponentiation.jl +++ b/src/Discretization/Exponentiation.jl @@ -428,8 +428,8 @@ end # compute the matrix Φ₂ = A^{-2} (exp(A*δ) - I - A*δ) assuming that A is invertible # and explicitly computing inv(A); this function optionally receives Φ = exp(Aδ) -# FIXME don't pass algorithm since it is ignore if Φ is given -#@time Φ2 = ReachabilityAnalysis._Φ₂_inv(abs.(A), δ, ReachabilityAnalysis.BaseExp, Φ); +# FIXME don't pass algorithm since it is ignored if Φ is given +# Φ2 = ReachabilityAnalysis._Φ₂_inv(abs.(A), δ, ReachabilityAnalysis.BaseExp, Φ) function _Φ₂_inv(A::AbstractMatrix, δ, alg, Φ=nothing) Aδ = A * δ if isnothing(Φ) diff --git a/test/models/hybrid/lotka_volterra.jl b/test/models/hybrid/lotka_volterra.jl index 7993213bf4..eb27a4ffe6 100644 --- a/test/models/hybrid/lotka_volterra.jl +++ b/test/models/hybrid/lotka_volterra.jl @@ -44,14 +44,14 @@ end # TEST RUN: prob = lotka_volterra_hybrid(nsplit=10, ε_ext=1e-4, n_int = 30, ε = 0.008); -@time sol = solve(prob, - tspan=(0.0, 3.64), - alg=TMJets(abstol=1e-12, orderT=7, orderQ=1, adaptive=true, disjointness=RA.ZonotopeEnclosure()), - max_jumps=2, - intersect_source_invariant=false, - intersection_method=RA.BoxIntersection(), - clustering_method=RA.BoxClustering(), - disjointness_method=RA.BoxEnclosure()); +sol = solve(prob, + tspan=(0.0, 3.64), + alg=TMJets(abstol=1e-12, orderT=7, orderQ=1, adaptive=true, disjointness=RA.ZonotopeEnclosure()), + max_jumps=2, + intersect_source_invariant=false, + intersection_method=RA.BoxIntersection(), + clustering_method=RA.BoxClustering(), + disjointness_method=RA.BoxEnclosure()); solz = overapproximate(sol, Zonotope); B = Ball2([1.0, 1.0], 0.15) # "exact" From 701fe0b70f3f41857f728b353e89471ec0ee4e00 Mon Sep 17 00:00:00 2001 From: schillic Date: Fri, 1 Mar 2024 17:41:55 +0100 Subject: [PATCH 2/2] rename FIXME -> TODO --- src/Algorithms/LGG09/reach_inhomog.jl | 2 +- src/Algorithms/QINT/post.jl | 6 +++--- src/Discretization/Exponentiation.jl | 4 ++-- src/Flowpipes/clustering.jl | 2 +- src/ReachSets/TaylorModelReachSet.jl | 6 +++--- src/ReachSets/TemplateReachSet.jl | 2 +- test/algorithms/ASB07.jl | 2 +- test/flowpipes/flowpipes.jl | 4 ++-- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/Algorithms/LGG09/reach_inhomog.jl b/src/Algorithms/LGG09/reach_inhomog.jl index 67db850ca7..d4560db44d 100644 --- a/src/Algorithms/LGG09/reach_inhomog.jl +++ b/src/Algorithms/LGG09/reach_inhomog.jl @@ -421,7 +421,7 @@ end # quote / load_krylov_LGG09_inhomog() # Methods using eigenvalues of the transition matrix # ------------------------------------------------------------ -#= FIXME needs review << +#= TODO needs review << # it is assumed that (λ, d) is an eigenvalue-eigenvector pair of the matrix Φᵀ function reach_inhomog_dir_eig_LGG09!(out::AbstractVector{N}, X₀, V, d::AbstractVector{N}, λ::N, NSTEPS) where {N} diff --git a/src/Algorithms/QINT/post.jl b/src/Algorithms/QINT/post.jl index 00912fc8c7..682299f684 100644 --- a/src/Algorithms/QINT/post.jl +++ b/src/Algorithms/QINT/post.jl @@ -1,5 +1,5 @@ # this algorithms assumes that the initial-value problem is one-dimensional -# FIXME requires special scalar quadratic system type +# TODO requires special scalar quadratic system type function reach_homog_QINT(alg::QINT{N}, ivp::IVP{<:AbstractContinuousSystem}, tspan; Δt0::TimeInterval=zeroI, kwargs...) where {N} n = statedim(ivp) @@ -8,7 +8,7 @@ function reach_homog_QINT(alg::QINT{N}, ivp::IVP{<:AbstractContinuousSystem}, ts @unpack Δ, δ, θ, maxiter, approx_model = alg - # normalize system to canonical form FIXME + # normalize system to canonical form TODO ivp_norm = _normalize(ivp) Ω0 = initial_state(ivp_norm) @@ -30,7 +30,7 @@ function reach_homog_QINT(alg::QINT{N}, ivp::IVP{<:AbstractContinuousSystem}, ts #F = Vector{ReachSet{N, IT}}(undef, NSTEPS) if got_homogeneous - # FIXME consider Δt0 + # TODO consider Δt0 F = reach_homog_QINT(; a=a, b=b, c=c, X0=Ω0, T=T, Δ=Δ, δ=δ, θ=θ, maxiter=maxiter) else error("not implemented yet") diff --git a/src/Discretization/Exponentiation.jl b/src/Discretization/Exponentiation.jl index 4af7e41e9f..a76f3303cd 100644 --- a/src/Discretization/Exponentiation.jl +++ b/src/Discretization/Exponentiation.jl @@ -33,7 +33,7 @@ Abstract supertype for all exponentiation algorithms. """ abstract type AbstractExpAlg end -# FIXME use _alias_exp to distinguish from setops +# TODO use _alias_exp to distinguish from setops # no-op _alias(alg::AbstractExpAlg) = alg @@ -428,7 +428,7 @@ end # compute the matrix Φ₂ = A^{-2} (exp(A*δ) - I - A*δ) assuming that A is invertible # and explicitly computing inv(A); this function optionally receives Φ = exp(Aδ) -# FIXME don't pass algorithm since it is ignored if Φ is given +# TODO don't pass algorithm since it is ignored if Φ is given # Φ2 = ReachabilityAnalysis._Φ₂_inv(abs.(A), δ, ReachabilityAnalysis.BaseExp, Φ) function _Φ₂_inv(A::AbstractMatrix, δ, alg, Φ=nothing) Aδ = A * δ diff --git a/src/Flowpipes/clustering.jl b/src/Flowpipes/clustering.jl index e8af5f851b..06420d5940 100644 --- a/src/Flowpipes/clustering.jl +++ b/src/Flowpipes/clustering.jl @@ -107,7 +107,7 @@ function cluster(F, idx, ::LazyClustering{Missing,Val{true}}) return [convexify(view(F, idx))] end -# FIXME return a UnionSetArray of reach-sets +# TODO return a UnionSetArray of reach-sets function cluster(F, idx, ::LazyClustering{Missing,Val{false}}) return [view(F, idx)] end diff --git a/src/ReachSets/TaylorModelReachSet.jl b/src/ReachSets/TaylorModelReachSet.jl index fda0f11ab6..12f71c59c2 100644 --- a/src/ReachSets/TaylorModelReachSet.jl +++ b/src/ReachSets/TaylorModelReachSet.jl @@ -130,7 +130,7 @@ function _is_intersection_empty(R::TaylorModelReachSet, Y::LazySet, method::Fall return isdisjoint(set(overapproximate(R, Zonotope)), Y) end -# FIXME when UnionSet, UnionSetArray <: LazySet +# TODO when UnionSet, UnionSetArray <: LazySet function _is_intersection_empty(R::TaylorModelReachSet, Y::Union{UnionSet,UnionSetArray}, method::FallbackDisjointness) return isdisjoint(set(overapproximate(R, Zonotope)), Y) @@ -359,7 +359,7 @@ function overapproximate(R::TaylorModelReachSet{N}, ::Type{<:Hyperrectangle}; if nsdiv == 1 partition = [S] else - # FIXME (also below) may use IA.mince directly + # TODO (also below) may use IA.mince directly partition = fill(nsdiv, D) Sdiv = LazySets.split(convert(Hyperrectangle, S), partition) partition = convert.(IntervalBox, Sdiv) @@ -461,7 +461,7 @@ function overapproximate(H::AbstractHyperrectangle{N}, T::Type{<:TaylorModelReac end # overapproximate a zonotopic set with a taylor model reachset -# FIXME pass algorithm option to choose between using parallelotope oa or order reduction +# TODO pass algorithm option to choose between using parallelotope oa or order reduction function overapproximate(Z::AbstractZonotope{N}, ::Type{<:TaylorModelReachSet}; orderQ::Integer=2, orderT::Integer=8, Δt::TimeInterval=zeroI, indices=1:dim(Z), box_reduction=false) where {N} diff --git a/src/ReachSets/TemplateReachSet.jl b/src/ReachSets/TemplateReachSet.jl index ad8d66a25f..eac91bea8b 100644 --- a/src/ReachSets/TemplateReachSet.jl +++ b/src/ReachSets/TemplateReachSet.jl @@ -58,7 +58,7 @@ function set(R::TemplateReachSet) return T([HalfSpace(di, R.sf[i]) for (i, di) in enumerate(R.dirs)]) end -# FIXME requires adding boundedness property as a type parameter +# TODO requires adding boundedness property as a type parameter setrep(::Type{<:TemplateReachSet{N,VN}}) where {N,VN} = HPolyhedron{N,VN} setrep(::TemplateReachSet{N,VN}) where {N,VN} = HPolyhedron{N,VN} diff --git a/test/algorithms/ASB07.jl b/test/algorithms/ASB07.jl index 0ff78c8256..2c9212d380 100644 --- a/test/algorithms/ASB07.jl +++ b/test/algorithms/ASB07.jl @@ -47,7 +47,7 @@ using ..Overapproximate: _convert_or_overapproximate sol1_nonrec = solve(P_lin; tspan=(0.0, 1.0), alg=ASB07(; δ=0.04, recursive=false)) @test diameter(set(sol1_rec[end])) < diameter(set(sol1_nonrec[end])) - # FIXME test without IntervalMatrix wrapper + # TODO test without IntervalMatrix wrapper #A = [-1.0 ± 0.05 -4.0 ± 0.05; # 4.0 ± 0.05 -1.0 ± 0.05] #P_lin = @ivp(x' = Ax, x(0) ∈ X0) diff --git a/test/flowpipes/flowpipes.jl b/test/flowpipes/flowpipes.jl index b3905cd5eb..d1cb166274 100644 --- a/test/flowpipes/flowpipes.jl +++ b/test/flowpipes/flowpipes.jl @@ -56,7 +56,7 @@ end @testset begin "Flowpipe inclusion" - # Projectile problem + # Projectile problem A = [0.0 0.5 0.0 0.0; 0.0 0.0 0.0 0.0; 0.0 0.0 0.0 0.7; 0.0 0.0 0.0 0.0] X0 = Singleton([0.0, 5.0, 100.0, 0]) U = Singleton([0.0, 0.0, 0.0, -9.81]) @@ -113,7 +113,7 @@ end δ = 0.1 F1 = Flowpipe([ReachSet(X, (0 .. δ) + k * δ) for k in 0:10]) - #= FIXME requires LazySets#2157 + #= TODO requires LazySets#2157 N = eltype(X) U1 = cluster(F1, 8:10, UnionClustering()) @test U1 isa Vector{ReachSet{N, UnionSetArray{N,Interval{N, IntervalArithmetic.Interval{N}}}}}