Hello,
I have a vector. Each element of the vector is a tuple that contains two elements, an interval, and a set of three intervals. I want to separate and take unions of those elements of the vector that contain an empty set in between. For example, I have a vector like-
9-element Vector{Any}:
([0, 2], ([100, 300], [1, 3], [10, 10]))
([2, 4], (∅, ∅, ∅))
([4, 6], (∅, ∅, ∅))
([6, 8], ([100, 300], [1, 3], [10, 10]))
([8, 10], ([100, 300], [1, 3], [10, 11]))
([10, 12], (∅, ∅, ∅))
([12, 14], (∅, ∅, ∅))
([14, 16], ([50, 252], [1.19, 3], [10, 10]))
([16, 18], ([100, 258], [1.16, 3], [10, 11]))
I want to get three IntervalBoxes, one is ([100, 300], [1, 3], [10, 10])
, second is the union of a second tuple of 5th and 6th element of the vector, ([100, 300], [1, 3], [10, 11])
, and third is a union of a second tuple of 8th and 9th elements of the vector, ([50, 258], [1.16, 3], [10, 11])
. Could you please help me with how to do it using the ‘IntervalArithmetic.jl’ package?
Thank you in advance.