ZPolyhedralSet - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


PolyhedralSets[ZPolyhedralSets]

  

ZPolyhedralSet

  

construct Z-polyhedral sets

 

Calling Sequence

Parameters

Options

Description

Examples

References

Compatibility

Calling Sequence

ZPolyhedralSet(constraints)

ZPolyhedralSet(constraints,vars,opts)

Parameters

constraints

-

list or set of linear equations and non-strict inequalities with rational number coefficients

vars

-

(optional) list of the variables in constraints that are regarded as unknowns, ordered in decreasing order

opts

-

(optional) one or more equations of the form keyword = value, where keyword is one of the names parameters, parameterconstraints, or lattice, described below

Options

• 

parameters = list of parameter names

  

This option can be used to explicitly list the parameters for a parameterized Z-polyhedral set. The default value is the list of all variables occurring in constraints, except those listed in vars; if vars is not specified, its default value is all variables occurring in constraints, so none are regarded as parameters.

• 

parameterconstraints = list or set of linear equations and non-strict inequalities with rational number coefficients

  

This option can be used to impose conditions on which parameter values are included. The default value is the empty list (impose no restrictions).

• 

lattice = lattice object, or list of a matrix and a vector

  

This option can be used to specify a lattice other than the default lattice, n. The dimension of the lattice should be the sum of the number of unknowns and the number of parameters.

Description

• 

A Z-polyhedral set is the intersection of a polyhedral set with an integer lattice. (A Z-polytope is the intersection of a polytope with an integer lattice; a polytope is a bounded polyhedral set.) This command constructs Maple representations of Z-polyhedral sets, possibly with parameters that occur linearly in the defining inequalities.

• 

ZPolyhedralSet(constraints) returns the Z-polyhedral set defined by the inequalities in constraints and the lattice n, with the unknowns in an arbitrarily chosen order. The order of the variables can impact the efficiency of some algorithms.

• 

ZPolyhedralSet(constraints, vars) imposes the given order on the variables. If any names in constraints are not included in vars, they are considered to be parameters. The order for the parameters is then arbitrarily chosen; this can still impact the efficiency of some algorithms, because internally some algorithms translate a parametric Z-polyhedral set to the Z-polyhedral set where all parameters are additional unknowns (ordered after the original unknowns), and the order of those unknowns then impacts efficiency.

• 

ZPolyhedralSet(constraints, vars, parameters = params) lists the parameters explicitly, and also specifies an order on the parameters. If vars is omitted, it consists of all variables in constraints not included in params. If vars is specified, then all variables in constraints need to be listed in either vars or params.

• 

ZPolyhedralSet(constraints, parameterconstraints = pcs) specifies conditions that involve only the parameters. If the parameters option and vars argument are not given, they default to the variables occurring in pcs and the rest of the variables in constraints, respectively; each ordered arbitrarily.

• 

ZPolyhedralSet(constraints, lattice = L) specifies the lattice, L, that is intersected with the polyhedral set. The default lattice is n. L can be a Lattice object as described on the Lattice help page. Alternatively, it can be a list consisting of an n×n Matrix and an n-dimensional Vector, out of which Maple will construct a Lattice object as described on that same help page.

• 

Z-polyhedral sets, or Z-polyhedra, are used to describe the integer points of a polyhedron (or polyhedral set). For more information, see the command IntegerPointDecomposition.

• 

Note that a Z-polyhedral set can also be the input of the command IntegerPointDecomposition. In fact, a Z-polyhedral set returned by the command IntegerPointDecomposition has additional algebraic properties that an arbitrary Z-polyhedral set is unlikely to have.  Those algebraic properties are specified in Definition 2 of the first reference listed below.  They imply that such a Z-polyhedral set, say zp, is consistent (that is, has at least one point) and is specializable. This latter property means that if x is the variable of lowest rank in vars and v is a possible value for x (that is, there exists at least one point of zp with v as x-coordinate) then all the points of zp with v as x-coordinate are given by specializing at x=v the constraints of linear inequalities defining zp.

• 

A parametric Z-Polyhedral set is a family of Z-polyhedral sets, given by a Z-polyhedral set where, in the defining linear constraints of inequalities, either the matrix or the right-hand side vector, depend linearly on parameters.  This notion is particularly useful in application problems, like parametric integer linear programming, where the feasible region, and thus the optimal solutions, depend on the values of parameters.

Examples

withPolyhedralSets:

withZPolyhedralSets:

Create a Z-polyhedron in the three-dimensional space with a system of two linear equations.

eqs7x+12y+31z=17,3x+5y+14z=7

eqs7x+12y+31z=17,3x+5y+14z=7

(1)

varsx,y,z

varsx,y,z

(2)

zpZPolyhedralSeteqs,vars

Apply IntegerPointDecomposition and obtain the integer solutions of that linear system.

decIntegerPointDecompositionzp:

newzpdec1

newzpRelations:x=13z1y=5z+2Variables:x,y,zParameters:ParameterConstraints:Lattice:ZSpan−1351,,,−120

(3)

Create a Z-polyhedral set in two-dimensional space with a system of three linear inequalities.

ineqsx+2y34,x+y1,111x+2411y

ineqsx+2y34,x+y1,x11+2411y

(4)

zpZPolyhedralSetineqs,x,y

Apply IntegerPointDecomposition and observe that it contains only one integer point.

decIntegerPointDecompositionzp

decRelations:x=2y=3Variables:x,yParameters:ParameterConstraints:Lattice:ZSpan01,,,20

(5)

Create another Z-polyhedron in two-dimensional space with a system of three linear inequalities.

ineqsx+2y34,x+y78,111x+2411y

ineqsx+2y34,x+y78,x11+2411y

(6)

zpZPolyhedralSetineqs,x,y

Apply IntegerPointDecomposition and observe that it is empty.

resIntegerPointDecompositionzp

res

(7)

Create another Z-polyhedron in the three-dimensional space with a system of five linear inequalities.

ineqs0x,0y,2x+3y12,3x+2y12,x+y1

ineqs0x,0y,x+y1,2x+3y12,3x+2y12

(8)

zpZPolyhedralSetineqs,x,y

Plot the polyhedral set defined over the rational numbers by the system ineqs.

pPolyhedralSetineqs

p{Coordinates:x,yRelations:y0,x0,x+y1,x+2y34,x+3y26

(9)

PolyhedralSet:-Plotp

Apply IntegerPointDecomposition to zp and obtain the integer solutions of the linear system ineqs

decIntegerPointDecompositionzp:

newzpdec1

newzpRelations:y2x0y0x+y13x+2y12Variables:x,yParameters:ParameterConstraints:Lattice:ZSpan1001,,,00

(10)

Create a parametric Z-Polyhedral set with two unknowns and two parameters

ineqsx_1+3x_292theta_1+theta_2,2x_1+x_28+theta_12theta_2,x_14+theta_1+theta_2,x_10,x_20

ineqsx_1+3x_292theta_1+theta_2,2x_1+x_28+theta_12theta_2,x_14+theta_1+theta_2,x_10,x_20

(11)

varsx_1,x_2

varsx_1,x_2

(12)

parastheta_1,theta_2

parastheta_1,theta_2

(13)

pzpZPolyhedralSetineqs,vars,parameters=paras

Apply IntegerPointDecomposition to pzp and obtain necessary and sufficient conditions on the parameters for  pzp to have integer solutions with vars as unknowns

decIntegerPointDecompositionpzp

decRelations:x_10x_20x_1theta_1theta_24x_2theta_1+2theta_283x_2+2theta_1theta_29x_1+3x_2+2theta_1theta_292x_1+x_2theta_1+2theta_28Variables:x_1,x_2Parameters:theta_1,theta_2ParameterConstraints:theta_28theta_25theta_1theta_24theta_1+2theta_282theta_1theta_29Lattice:ZSpan1000010000100001,,,0000

(14)

References

  

Rui-Juan Jing and Marc Moreno Maza. "Computing the Integer Points of a Polyhedron, I: Algorithm." Proceedings of CASC 2017: 225-241, Springer.

  

Rui-Juan Jing and Marc Moreno Maza. "Computing the Integer Points of a Polyhedron, II: Complexity Estimates." Proceedings of CASC 2017: 242-256, Springer.

  

Rachid Seghir, Vincent Loechner, and Benoı̂t Meister. "Integer affine transformations of parametric Z-polytopes and applications to loop nest optimization." Proceedings of TACO, Vol. 9(2):8:1–8:27, 2012.

  

William Pugh. "The omega test: a fast and practical integer programming algorithm for dependence analysis." Proceedings Supercomputing ’91, pp 4–13. ACM, 1991.

  

William Pugh. "Counting solutions to presburger formulas: How and why." Proceedings of PLDI, pp 121–134. ACM, 1994.

Compatibility

• 

The PolyhedralSets:-ZPolyhedralSets:-ZPolyhedralSet package was introduced in Maple 2023.

• 

For more information on Maple 2023 changes, see Updates in Maple 2023.

See Also

ZPolyhedralSets:-IsEmpty

ZPolyhedralSets:-IsIntegerPointOf

ZPolyhedralSets:-SamplePoint

ZPolyhedralSets:-IntegerPointDecomposition

ZPolyhedralSets:-EnumerateIntegerPoints

ZPolyhedralSets:-ZPolyhedralSet

ZPolyhedralSets

PolyhedralSets