Union
Purpose
Represents a general union of convex sets in MPT
Syntax
U = Union(Set)
Description
The Union object represent collection of various convex sets. The
only restriction for the sets is to be convex, i.e. they have to be derived from
the ConvexSet class.
You can associate functions to any of the set via addFunction method of the
ConvexSet class. Function handles and all properties of the sets can be
accessed via Union.Set property based on the index.
For a list of available methods type "methods('Union')".
Input Arguments
Set |
Any object derived from the ConvexSet class.
Class: ConvexSet
|
Output Arguments
U |
Object of the Union class.
Class: Union
|
Example(s)
Example
1
Construct union of two YSet objects. Define the objects in YALMIP x = sdpvar(2,1);
F1 = [0<= x <=1];
F2 = [ norm(x-[1;1]) <= 1];
Y(1) = YSet(x,F1);
Y(2) = YSet(x,F2);
Create the union U=Union(Y)
Union of 2 convex sets.
Functions : none
Plot the union U.plot

Example
2
Construt the union of two polyhedra in 1D. Define the polyhedra P(1) = Polyhedron('lb',-5,'ub',1);
P(2) = Polyhedron('lb',0);
Create the union U = Union(P)
Union of 2 convex sets.
Functions : none
Plot the polyhedra U.plot('linewidth',3)

See Also
yset, polyhedron, polyunion
◀ |
listfunctions |
|
hasfunction |
▶ |
© 2010-2013 Martin Herceg: ETH Zurich, herceg@control.ee.ethz.ch