ReachabilityAnalysis.jl icon indicating copy to clipboard operation
ReachabilityAnalysis.jl copied to clipboard

Functionality for property checking on a given mode

Open mforets opened this issue 4 years ago • 0 comments

Some properties should hold only for some locations; for example, the following function (taken from the spacecraft model, see this repo) checks whether the secnd location of the hybrid flowpipe in sol is contained in the given cone.

function line_of_sight(sol, cone)
    all_idx = findall(x -> x == 2, location.(sol))  # attempt
    for idx in all_idx
        verif = all(set(R) ⊆ cone for R in sol[idx])
        !verif && return false
    end
    return true
end

It would be convenient to introduce some syntax for this type of check, such as

sol(location=2) ⊆ cone

or similar.

mforets avatar Jul 01 '20 05:07 mforets