Test if a union of polyhedra is contained inside another union.
U1 <= U2
U1 |
Union of polyhedra in the same dimension. Class: PolyUnion |
U2 |
Union of polyhedra in the same dimension. Class: PolyUnion |
tf |
True if U1 <= U2 and false otherwise. Class: logical Allowed values:
|
rectangle = Polyhedron('lb',[-2;-1],'ub',[4;5]);Cut the the rectangle into pieces by extracting an inner part.
T = rectangle \ (0.2*rectangle);Create an union of these pieces.
U1 = PolyUnion('Set',T,'FullDim',true,'Connected',true,'Convex',false,'Overlaps',false,'Bounded',true);
U1.plot
U2 = PolyUnion(rectangle);
U1 <= U2
ans = 1The inner rectangle is not contained inside the union.
U3 = PolyUnion(0.2*rectangle);
U1 <= U3
ans = 0
◀ | mpt | outerapprox | ▶ |
© 2003-2013 Michal Kvasnica: STU Bratislava, michal.kvasnica@stuba.sk