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

Online Help

All Products    Maple    MapleSim


RegularChains[SemiAlgebraicSetTools]

  

CylindricalAlgebraicDecompose

  

compute an F-invariant cylindrical algebraic decomposition

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

CylindricalAlgebraicDecompose(F, R, outopt, methopt)

CylindricalAlgebraicDecompose(lsas, R, outopt, methopt, optopt)

Parameters

F

-

list of polynomials of R

R

-

polynomial ring

lsas

-

list of semi-algebraic systems of R

outopt

-

(optional) keyword option of the form output = value

methopt

-

(optional) keyword option of the form method = value

optopt

-

(optional) keyword option of the form optimization = value

Description

• 

CylindricalAlgebraicDecompose(F, R) returns an F-invariant cylindrical algebraic decomposition of the n-dimensional real space, where n is the number of variables in R. This assumes that R has characteristic zero and no parameters, such that the base field of R is the field of rational numbers.

• 

A cylindrical algebraic decomposition (CAD) of the n-dimensional real space is a partition of the whole space into connected semi-algebraic subsets such that the cells in the partition are cylindrically arranged, that is, the projection of any two cells onto any lower dimensional real space is either equal or disjoint. This decomposition is called F-invariant if for any given cell, the sign of each polynomial in F does not change over the cell.

• 

The output of CylindricalAlgebraicDecompose(F, R) has several possible formats controlled by the option outopt. Its possible values are 'output'='piecewise', 'output'='tree', 'output'='list' , 'output'='cadcell' and 'output'='rootof'.

  

In all formats, each cell provides at least two pieces of information, the index of the cell and a sample point of the cell.

  

In the 'output'='cadcell' and 'output'='rootof' formats, a defining semi-algebraic system (called a Tarski Formula) is also provided.

  

Due to the cylindricity property, cells can be organized in a hierarchical manner. This is the purpose of 'output'='piecewise' and 'output'='tree', whereas the other three formats are flat representations.

  

Due to the potentially large number of cells, the 'output'='cadcell' format only shows the name cadcell for each cell in the decomposition. However, cadcell is a type and an object of that type can be passed to Display. It can also be passed to SamplePoints in order to access the sample point of the cell.

  

The 'output'='rootof' format is meant to be compatible with the output format of the solve command.

• 

For the commands CylindricalAlgebraicDecompose(lsas, R, output=cadcell) and CylindricalAlgebraicDecompose(lsas, R, output=rootof), the input parameter lsas is a list of semi-algebraic systems. Each of these is a list of polynomial equations, inequations or inequalities given by polynomials of R. If R has n variables, a point in the n-dimensional real space satisfies such a semi-algebraic system if and only this point satisfies all the equations, inequations or inequalities of that system simultaneously.

• 

The commands CylindricalAlgebraicDecompose(lsas, R, output=cadcell) and CylindricalAlgebraicDecompose(lsas, R, output=rootof) compute a cylindrical algebraic decomposition of all the input polynomials occurring in lsas and return only the cells satisfying at least one of the input semi-algebraic systems.

• 

For these two commands, the specification of 'output'='cadcell' and 'output'='rootof' is as above.

  

The default algorithm of CylindricalAlgebraicDecompose is an incremental algorithm (CM) based on triangular decompositions, and proposed by Changbo Chen and Marc Moreno Maza in ASCM 2012. This default algorithm is also available through the option method=incremental. An alternative algorithm (CMXY) proposed by Changbo Chen, Marc Moreno Maza, Bican Xia and Lu Yang at ISSAC 2009, which is also the first generation of algorithm for computing CAD based on triangular decompositions, is available through the option method=recursive.

• 

The CM algorithm can take advantage of equational constraints given in a single semi-algebraic system.  That is, if the input is a list of polynomial constraints involving equations, by default, the option optimization=EC is enabled. To disable such optimization, one sets optimization=false.

• 

If the input is a list of polynomial constraints, by default, an algorithm (RC-TTICAD) for computing truth-table invariant CAD is used to compute a smaller CAD. One can use the option optimization=TTICAD or optimization=EC to enable or disable it, respectively.  

• 

For mathematical definitions of the types squarefree_semi_algebraic_system, semi_algebraic_set and cad_cell, see the SemiAlgebraicSetTools help page.

• 

Variable orders play a crucial role in the efficiency of CAD computation. The command SuggestVariableOrder computes such orders heuristically.

Examples

withRegularChains:

withChainTools:

withSemiAlgebraicSetTools:

Define a ring of polynomials.

RPolynomialRingy,x

Rpolynomial_ring

(1)

Define a set of equations.

Fxy1

Fxy1

(2)

Compute an F-invariant cylindrical algebraic decomposition of the plane.

cadCylindricalAlgebraicDecomposeF,R

cadc_a_d

(3)

The output CAD is described by a nested piecewise function. The outmost piecewise function is a function with three conditions x<0, x=0, and 0<x. Each of the conditions has a corresponding expression, which is again a piecewise function. The output could be read from top to bottom and from right to left. The other two formats are shown below.

cadCylindricalAlgebraicDecomposeF&comma;R&comma;output=tree

cad1&comma;−1&comma;x&comma;1&comma;regular_chain&comma;12&comma;12&comma;−1&comma;yx1&comma;1&comma;regular_chain&comma;12&comma;12&comma;52&comma;52&comma;yx1&comma;1&comma;regular_chain&comma;12&comma;12&comma;−2&comma;−2&comma;1&comma;yx1&comma;1&comma;regular_chain&comma;12&comma;12&comma;32&comma;32&comma;x&comma;1&comma;regular_chain&comma;0&comma;0&comma;1&comma;regular_chain&comma;0&comma;0&comma;0&comma;0&comma;1&comma;x&comma;1&comma;regular_chain&comma;12&comma;12&comma;−1&comma;yx1&comma;1&comma;regular_chain&comma;12&comma;12&comma;32&comma;32&comma;yx1&comma;1&comma;regular_chain&comma;12&comma;12&comma;2&comma;2&comma;1&comma;yx1&comma;1&comma;regular_chain&comma;12&comma;12&comma;52&comma;52

(4)

cadCylindricalAlgebraicDecomposeF&comma;R&comma;output=list

cad1&comma;1&comma;regular_chain&comma;12&comma;12&comma;52&comma;52&comma;1&comma;2&comma;regular_chain&comma;12&comma;12&comma;−2&comma;−2&comma;1&comma;3&comma;regular_chain&comma;12&comma;12&comma;32&comma;32&comma;2&comma;1&comma;regular_chain&comma;0&comma;0&comma;0&comma;0&comma;3&comma;1&comma;regular_chain&comma;12&comma;12&comma;32&comma;32&comma;3&comma;2&comma;regular_chain&comma;12&comma;12&comma;2&comma;2&comma;3&comma;3&comma;regular_chain&comma;12&comma;12&comma;52&comma;52

(5)

For a more complicated example, compute the cylindrical algebraic decomposition of the parametric parabola. The output is a CAD of four-dimensional real space with 27 cells.

RPolynomialRingx&comma;c&comma;b&comma;a

Rpolynomial_ring

(6)

Fax2+bx+c

Fax2+bx+c

(7)

The default is the piecewise format. When many cells are present the 'output'='cadcell' and 'output'='rootof' formats are useful.

cadCylindricalAlgebraicDecomposeF&comma;R&comma;output=cadcell

cadcad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell

(8)

cadCylindricalAlgebraicDecomposeF&comma;R&comma;output=rootof

cada<0&comma;b=b&comma;c<b24a&comma;x=x&comma;a<0&comma;b=b&comma;c=b24a&comma;x<b2a&comma;a<0&comma;b=b&comma;c=b24a&comma;x=b2a&comma;a<0&comma;b=b&comma;c=b24a&comma;b2a<x&comma;a<0&comma;b=b&comma;b24a<c&comma;x<b+4ca+b22a&comma;a<0&comma;b=b&comma;b24a<c&comma;x=b+4ca+b22a&comma;a<0&comma;b=b&comma;b24a<c&comma;b+4ca+b22a<xx<b+4ca+b22a&comma;a<0&comma;b=b&comma;b24a<c&comma;x=b+4ca+b22a&comma;a<0&comma;b=b&comma;b24a<c&comma;b+4ca+b22a<x&comma;a=0&comma;b<0&comma;c=c&comma;x<cb&comma;a=0&comma;b<0&comma;c=c&comma;x=cb&comma;a=0&comma;b<0&comma;c=c&comma;cb<x&comma;a=0&comma;b=0&comma;c<0&comma;x=x&comma;a=0&comma;b=0&comma;c=0&comma;x=x&comma;a=0&comma;b=0&comma;0<c&comma;x=x&comma;a=0&comma;0<b&comma;c=c&comma;x<cb&comma;a=0&comma;0<b&comma;c=c&comma;x=cb&comma;a=0&comma;0<b&comma;c=c&comma;cb<x&comma;0<a&comma;b=b&comma;c<b24a&comma;x<b+4ca+b22a&comma;0<a&comma;b=b&comma;c<b24a&comma;x=b+4ca+b22a&comma;0<a&comma;b=b&comma;c<b24a&comma;b+4ca+b22a<xx<b+4ca+b22a&comma;0<a&comma;b=b&comma;c<b24a&comma;x=b+4ca+b22a&comma;0<a&comma;b=b&comma;c<b24a&comma;b+4ca+b22a<x&comma;0<a&comma;b=b&comma;c=b24a&comma;x<b2a&comma;0<a&comma;b=b&comma;c=b24a&comma;x=b2a&comma;0<a&comma;b=b&comma;c=b24a&comma;b2a<x&comma;0<a&comma;b=b&comma;b24a<c&comma;x=x

(9)

The usage of input lists of semi-algebraic systems is illustrated below.

RPolynomialRingx&comma;a&comma;b

Rpolynomial_ring

(10)

cadCylindricalAlgebraicDecomposex2a&comma;x+b&comma;R&comma;output=cadcell

cadcad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell&comma;cad_cell

(11)

cadCylindricalAlgebraicDecomposex2a=0&comma;x+b=0&comma;R&comma;output=cadcell

cadcad_cell

(12)

cadCylindricalAlgebraicDecomposex2a=0&comma;x+b=0&comma;R&comma;output=rootof

cadb=b&comma;a=b2&comma;x=b

(13)

To understand the effect of a list of two semi-algebraic systems, consider the following very simple example.

cadCylindricalAlgebraicDecomposexa&comma;R&comma;output=rootof

cadb=b&comma;a=a&comma;x<a&comma;b=b&comma;a=a&comma;x=a&comma;b=b&comma;a=a&comma;a<x

(14)

cadCylindricalAlgebraicDecompose0<xa&comma;R&comma;output=rootof

cadb=b&comma;a=a&comma;a<x

(15)

cadCylindricalAlgebraicDecomposex+b&comma;R&comma;output=rootof

cadb=b&comma;a=a&comma;x<b&comma;b=b&comma;a=a&comma;x=b&comma;b=b&comma;a=a&comma;b<x

(16)

cadCylindricalAlgebraicDecomposex+b=0&comma;R&comma;output=rootof

cadb=b&comma;a=a&comma;x=b

(17)

cadCylindricalAlgebraicDecomposex+b=0&comma;0<xa&comma;R&comma;output=rootof

cadb=b&comma;a<b&comma;a<x&comma;b=b&comma;a=b&comma;bx&comma;b=b&comma;b<a&comma;x=b&comma;b=b&comma;b<a&comma;a<x

(18)

The usage of the different methods and optimizations is illustrated below.

RPolynomialRingy&comma;x

Rpolynomial_ring

(19)

Fy2x

Fy2x

(20)

cadCylindricalAlgebraicDecomposeF&comma;R&comma;method=recursive&comma;output=piecewise

cad1x<01y<01y=010<yx=01y<x1y=x1x<yy<x1y=x1x<y0<x

(21)

RPolynomialRingy&comma;x

Rpolynomial_ring

(22)

Fx2+y21=0&comma;y2x=0

Fx2+y21=0&comma;y2x=0

(23)

cadCylindricalAlgebraicDecomposeF&comma;R&comma;optimization=EC&comma;output=allcell&colon;

nopscad

9

(24)

cad2CylindricalAlgebraicDecomposeF&comma;R&comma;optimization=false&comma;output=allcell&colon;

nopscad2

53

(25)

Compatibility

• 

The lsas parameter was introduced in Maple 16.

• 

The output option was introduced in Maple 16.

• 

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

• 

The RegularChains[SemiAlgebraicSetTools][CylindricalAlgebraicDecompose] command was updated in Maple 2020.

• 

The method and optimization options were introduced in Maple 2020.

• 

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

See Also

ComprehensiveTriangularize

CylindricalDecompose

Display

PartialCylindricalAlgebraicDecomposition

RealComprehensiveTriangularize

RealRootClassification

RealTriangularize

RegularChains

SamplePoints

SemiAlgebraicSetTools

SeparateZeros

SuggestVariableOrder

Triangularize