Acceleration of Solving MINLPs by Symbolic Computation
4.3 Symbolic computation
4.3 Symbolic computation
As we discussed at the end of Section 4.2.2, to replace constraints ((2.1), (2.7), (4.1), (4.2)) by constraints ((4.3), (4.4), (4.5)), we need to know the function๐๐for every node๐in a semi-passive network๐บ๐ . Consider CNS(๐บ๐ ) again. For every arc๐there is a function๐๐with๐๐=๐๐(๐๐ ), where๐๐is continuous, decreasing, increasing or constant. The flow direction through arc๐, which corresponds to the sign of๐๐, is said to be decided with inflow๐๐ โ โ := [๐1๐ , ๐2๐ ]if ๐๐ โค0or๐๐ โฅ0for all๐๐ โ โ. Since one of๐๐(๐1๐ )and๐๐(๐2๐ )is the maximum and the other is the minimum of๐๐, the flow direction is decided if and only if
๐๐(๐1๐ )ยท๐๐(๐2๐ )โฅ0.
With this property we make the following definition.
Definition 4.5 (Flow direction decided domain)
A domainโ := [๐1๐ , ๐2๐ ]with two constants๐1๐ , ๐2๐ โRis said to be aflow direction decided domainif for every arc๐โ ๐๐ it holds
๐๐(๐1๐ )ยท๐๐(๐2๐ )โฅ0.
Note that such a flow direction decided domain always exists. Because for any๐0๐ โ R a given constant, there exists an๐ > 0so that for every arc๐, either๐๐ = ๐๐(๐๐ ) โค 0or
as constants or parameter and all๐๐,โ๐ as variables. Note that๐๐กcan be eliminated since it depends only on value of๐๐ .
Before we solve SPE๐(๐บ๐ ), we look at the definitions and theorems concerning varieties and ideals. These are taken from the book of Cox et al. [CLO92].
Definition 4.6 (Ideal)
Let๐be a field. A subset๐ผ โ๐[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐]of the polynomial ring๐[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐]is an idealif it satisfies:
โข 0โ๐ผ;
โข if๐, ๐โ๐ผ, then๐+๐โ๐ผ;
โข if๐ โ๐ผandโโR[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐], thenโ๐ โ๐ผ. Definition 4.7 (Affine variety and polynomial ideal)
Let๐be a field and๐1, ๐2, . . . , ๐๐ be polynomials in๐[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐].Then we set V(๐1, ๐2, . . . , ๐๐ ) ={(๐1, . . . , ๐๐)โ๐๐:๐๐(๐1, . . . , ๐๐) = 0for all1โค๐โค๐ }.
We callV(๐1, ๐2, . . . , ๐๐ )theaffine varietydefined by๐1, ๐2, . . . , ๐๐ . Further we set
โจ๐1, . . . , ๐๐ โฉ= {๏ธ ๐
โ๏ธ
๐ก=1
โ๐ก๐๐ก:โ1, . . . , โ๐ โ๐[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐] }๏ธ
.
Note that๐ผ :=โจ๐1, . . . , ๐๐ โฉis an ideal, a proof can be found in the book of Cox et al. [CLO92].
We denote alsoV(๐ผ) =V(๐1, ๐2, . . . , ๐๐ )as the affine variety defined by๐1, ๐2, . . . , ๐๐ . From that book we have also the following theorem.
Theorem 4.8 (Elimination and Extension Theory)
Let๐ผ be a polynomial ideal with๐ผ = โจ๐1, . . . , ๐๐ โฉ โ C[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐]where V(๐ผ) is not an empty set. Assume there exists๐๐(๐ฅ๐) โC[๐ฅ๐]such that๐๐(๐ฅ๐) โ ๐ผ for one๐ โ {1, . . . , ๐}. It follows then
โข if๐ฅยฏ๐โCwith๐๐(ยฏ๐ฅ๐) = 0, then there exists(๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐)โV(๐ผ)such that๐ฅ๐ = ยฏ๐ฅ๐;
โข for any(๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐)โV(๐ผ), it holds๐๐(๐ฅ๐) = 0.
Furthermore,V(๐ผ)is a finite set if and only if there exists๐๐(๐ฅ๐)โC[๐ฅ๐]with๐๐(๐ฅ๐)โ๐ผ for any ๐โ {1, . . . , ๐}.
Note that Theorem 4.8 may not be true if we replaceCbyR, sinceRis not algebraically closed, e.g., the polynomial๐ฅ2+ 1โR[๐ฅ]has no root inRbut has a root inC. However, the ideal๐ผcan be selected so that all๐๐ โR[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐]โC[๐ฅ1, ๐ฅ2, . . . , ๐ฅ๐].
Consider the system of polynomial equations SPE๐(๐บ๐ )with a given flow direction decided domainโ again. Let๐ห1,๐ห2, . . . ,๐ห๐ be all polynomials in SPE๐(๐บ๐ )which generate an ideal ๐ผ =โจ๐ห1, . . . ,๐ห๐ โฉ. The set๐(๐ผ)is not an empty set since for parameter๐๐ โ โthe corresponding CNS(๐บ๐ )has a solution which is also of solution of SPE๐(๐บ๐ ). According to Theorem 4.4, for any fixed given๐๐ the polynomial system SPE๐(๐บ๐ )has a unique solution. We handle๐๐ as symbolic parameter but not a parameter. Then Theorem 4.8 implies that the corresponding set
4.3 Symbolic computation
๐(๐ผ)is finite while๐ผ is generated by all polynomials in SPE๐(๐บ๐ )Then for every variableโ๐ or๐๐, polynomials of the form๐๐(โ๐)or๐๐(๐๐)can be found by computing the Grรถbner bases with appropriately chosen monomial orderings [Laz83]. There are several software packages, e.g., Maple [Map] and Singular [DGPS12] which can compute Grรถbner bases and can check whether the affine variety of a given polynomial system is a finite set. Examples of applications using Maple can be found in [MG94; GDS94; Zac96; RlRmL14; GKZ90].
On the one hand, all of๐๐(โ๐)and๐๐(๐๐)can be regarded as univariate functions which contain symbolic parameter๐๐ , every root of๐๐(โ๐)and๐๐(๐๐)is a function that maps๐๐
toโ๐ or to๐๐. On the other hand, for any fixed๐๐ โ โ, the unique solution for CNS(๐บ๐ )in Theorem 4.4 is a solution for SPE๐(๐บ๐ )as well. It implies thatโ๐ =๐๐(๐๐ )is a root for๐๐(โ๐) for all๐๐ โ โ and for all nodes๐. Similarly,๐๐=๐๐(๐๐ )is a root for๐๐(๐๐)for all๐๐ โ โ and for all arcs๐. According to Abel-Ruffini theorem [Sko11], there is no algebraic solution to the general univariate polynomial equations of degree five or higher with arbitrary coefficients.
It is clear that the roots for a general univariate polynomial can be found if and only if the degree is no more than4. Assume that the degree of๐๐(โ๐)is๐๐ โค4(in our instance we have ๐๐ = 4), then all๐๐ roots๐1, ๐2, . . . , ๐๐๐ can be found by using Maple or Singular. Note that every๐๐can be regarded as a function that maps๐๐ toโ๐ if all other parameters are given as constants. With any fixed๐ยฏ๐ โ โ, the unique solution of CNS(๐บ๐ )can be found by using any NLP solver, e.g. SCIP.
Let๐1, . . . , ๐๐๐be the๐๐roots of polynomial๐๐(โ๐). Since any๐๐can be regarded as univariate function of ๐๐ , Theorem 4.4 and Theorem 4.8 imply together that there exists exactly one
ยฏ๐ โ {1, . . . , ๐๐}such that๐๐(๐๐ ) =๐ยฏ๐(๐๐ )in domainโ.
since๐ยฏ๐ is the unique candidate. We call the solution with๐๐ = ยฏ๐๐ adistinction solution. Simi-larly, all other functions๐๐and๐๐in domainโcan be found if the degree of the corresponding polynomial is no more than4and a distinction solution can be found.
Let[๐min๐ , ๐max๐ ]be the domain of๐๐ . Recall that all constraints ((2.1), (2.7), (4.1), (4.2)) related to ๐บ๐ in the entire MINLP can be replaced by constraints ((4.3), (4.4), (4.5)), where only functions ๐๐ appear in these new constraints. We design algorithm 4.1 to compute ๐๐
symbolically for an arbitrarily selected node๐. In this algorithm, in the first part, we split the original domain[๐min๐ , ๐max๐ ]to a set of sub-domains such that in every sub-domain is a flow direction decided domain. After that, we compute๐๐ in every sub-domain separately. The correctness of the theorem is proved.
Theorem 4.9 (Correctness of Algorithm 4.1)
Algorithm 4.1 finds๐๐ as defined in Theorem 4.4 if the algorithm terminates with โsuccessโ.
Algorithm 4.1:Symbolic computation to get๐๐
Input: A semi-passive subnetwork๐บ๐ , domain[๐min๐ , ๐max๐ ]for๐๐ and node๐ Output: Function๐๐related to Theorem 4.4 for๐๐ โ[๐min๐ , ๐max๐ ]
1 Initialize๐ฎ :={[๐min๐ , ๐max๐ ]};
2 Get the solution of CNS(๐บ๐ )with๐๐ =๐min๐ and๐๐ =๐max๐ using an NLP solver. Let๐ยด๐ and๐`๐be the value of๐๐for every arc๐in the solution with๐๐ =๐min๐ and๐๐ =๐max๐ , respectively.
3 for๐โ ๐๐ do
4 if๐ยด๐ยท๐`๐<0then
5 Solve CNS(๐บ๐ )with additional constraint๐๐= 0, let๐ยฏ๐ be the value of๐๐ in the unique solution;
6 Get the intervalโ๐โ ๐ฎ which is[๐1, ๐2)(or[๐1, ๐2]) and contains๐ยฏ๐ ;
7 if๐ยฏ๐ โ(๐1, ๐2)then
8 Replaceโ๐by[๐1,๐ยฏ๐ )and[ ยฏ๐๐ , ๐2)(or[ ยฏ๐๐ , ๐2]) in๐ฎ;
9 end
10 end
11 end
12 foreveryโ๐ โ ๐ฎ do
13 Get sign assignment๐according to (4.6) for๐๐ โ โ๐, construct the corresponding SPE๐(๐บ๐ );
14 Get๐๐(โ๐)by computing Grรถbner bases ;
15 if๐๐(โ๐)doesnotexistthen
16 Reportโnot a finite setโandstop
17 end
18 Let๐๐be the degree ;
19 if๐๐ >4then
20 Reportโdegree too highโandstop
21 end
22 Compute roots๐1, . . . , ๐๐๐;
23 whiletruedo
24 Choose a๐ยฏ๐ โ โ๐(randomly) and compute the solution of CNS(๐บ๐ )with๐๐ = ยฏ๐๐ ;
25 ifthe solution is a distinction solutionthen
26 Getยฏ๐and set๐๐(๐๐ )|๐๐ โโ๐ :=๐ยฏ๐(๐๐ );
27 break
28 end
29 end
30 end
31 Report โsuccessโ and return๐๐