diff --git a/src/ReachSets/ContinuousPost/BFFPS19/reach.jl b/src/ReachSets/ContinuousPost/BFFPS19/reach.jl index 69f5d2f5..c37d411b 100644 --- a/src/ReachSets/ContinuousPost/BFFPS19/reach.jl +++ b/src/ReachSets/ContinuousPost/BFFPS19/reach.jl @@ -1,7 +1,7 @@ using ..Utils: LDS, CLCDS -using LazySets: CacheMinkowskiSum, - isdisjoint +using LazySets: CachedMinkowskiSumArray, + isdisjoint import LazySets.Approximations: overapproximate @@ -140,10 +140,10 @@ function reach_mixed(problem::Union{IVP{<:CLDS{NUM}, <:LazySet{NUM}}, # first set in a series function _f(k, i, x::LinearMap{NUM}) where {NUM} @assert k == 1 "a LinearMap is only expected in the first iteration" - return CacheMinkowskiSum(LazySet{NUM}[x]) + return CachedMinkowskiSumArray(LazySet{NUM}[x]) end # further sets of the series - function _f(k, i, x::MinkowskiSum{NUM, <:CacheMinkowskiSum}) where NUM + function _f(k, i, x::MinkowskiSum{NUM, <:CachedMinkowskiSumArray}) where NUM if has_constant_directions(block_options_iter, i) # forget sets if we do not use epsilon-close approximation forget_sets!(x.X) @@ -152,7 +152,7 @@ function reach_mixed(problem::Union{IVP{<:CLDS{NUM}, <:LazySet{NUM}}, if lazy_inputs_interval(k) # overapproximate lazy set y = overapproximate_fun(i, x.X) - return CacheMinkowskiSum(LazySet{NUM}[y]) + return CachedMinkowskiSumArray(LazySet{NUM}[y]) end return x.X end diff --git a/src/ReachSets/ContinuousPost/BFFPSV18/check_property.jl b/src/ReachSets/ContinuousPost/BFFPSV18/check_property.jl index 1d392843..c13c8fef 100644 --- a/src/ReachSets/ContinuousPost/BFFPSV18/check_property.jl +++ b/src/ReachSets/ContinuousPost/BFFPSV18/check_property.jl @@ -1,4 +1,4 @@ -using LazySets: CacheMinkowskiSum +using LazySets: CachedMinkowskiSumArray """ check_property(S, property, options) @@ -92,10 +92,10 @@ function check_property(S::IVP{<:AbstractDiscreteSystem}, # first set in a series function _f(k, i, x::LinearMap{NUM}) where {NUM} @assert k == 1 "a LinearMap is only expected in the first iteration" - return CacheMinkowskiSum(LazySet{NUM}[x]) + return CachedMinkowskiSumArray(LazySet{NUM}[x]) end # further sets of the series - function _f(k, i, x::MinkowskiSum{NUM, <:CacheMinkowskiSum}) where NUM + function _f(k, i, x::MinkowskiSum{NUM, <:CachedMinkowskiSumArray}) where NUM if has_constant_directions(block_options_iter, i) # forget sets if we do not use epsilon-close approximation forget_sets!(x.X) @@ -104,7 +104,7 @@ function check_property(S::IVP{<:AbstractDiscreteSystem}, if lazy_inputs_interval(k) # overapproximate lazy set y = overapproximate_fun(i, x.X) - return CacheMinkowskiSum(LazySet{NUM}[y]) + return CachedMinkowskiSumArray(LazySet{NUM}[y]) end return x.X end diff --git a/src/ReachSets/ContinuousPost/BFFPSV18/reach.jl b/src/ReachSets/ContinuousPost/BFFPSV18/reach.jl index 05032832..ee345deb 100644 --- a/src/ReachSets/ContinuousPost/BFFPSV18/reach.jl +++ b/src/ReachSets/ContinuousPost/BFFPSV18/reach.jl @@ -1,7 +1,7 @@ using ..Utils: LDS, CLCDS -using LazySets: CacheMinkowskiSum, - isdisjoint +using LazySets: CachedMinkowskiSumArray, + isdisjoint import LazySets.Approximations: overapproximate @@ -120,10 +120,10 @@ function reach(problem::Union{IVP{<:CLDS{NUM}, <:LazySet{NUM}}, # first set in a series function _f(k, i, x::LinearMap{NUM}) where {NUM} @assert k == 1 "a LinearMap is only expected in the first iteration" - return CacheMinkowskiSum(LazySet{NUM}[x]) + return CachedMinkowskiSumArray(LazySet{NUM}[x]) end # further sets of the series - function _f(k, i, x::MinkowskiSum{NUM, <:CacheMinkowskiSum}) where NUM + function _f(k, i, x::MinkowskiSum{NUM, <:CachedMinkowskiSumArray}) where NUM if has_constant_directions(block_options_iter, i) # forget sets if we do not use epsilon-close approximation forget_sets!(x.X) @@ -132,7 +132,7 @@ function reach(problem::Union{IVP{<:CLDS{NUM}, <:LazySet{NUM}}, if lazy_inputs_interval(k) # overapproximate lazy set y = overapproximate_fun(i, x.X) - return CacheMinkowskiSum(LazySet{NUM}[y]) + return CachedMinkowskiSumArray(LazySet{NUM}[y]) end return x.X end diff --git a/test/Reachability/solve_continuous.jl b/test/Reachability/solve_continuous.jl index 743b3a8f..8db0cf7d 100644 --- a/test/Reachability/solve_continuous.jl +++ b/test/Reachability/solve_continuous.jl @@ -106,6 +106,11 @@ s = solve(IVP(LCS(sparse(A)), X0), op=BFFPSV18(:vars=>[1,3], :partition=>[1:2, 3:4], :exp_method=>"lazy", :assume_sparse=>true)) +s = solve(IVP(LCS(A), X0), + Options(:T=>0.1), + op=BFFPSV18(:vars=>[1,3], :partition=>[1:2, 3:4], + :lazy_inputs_interval => (k -> false))) + # uses Interval for set_type_init and set_type_iter but Hyperrectangle for # set_type_proj s = solve(IVP(LCS(sparse(A)), X0),