|
 |
Inequality Solving
Q:
Are there built-in functions for solving sets of (linear) equations and optimization problems, finding a solution that satisfies certain strict inequalities (e.g., ), and non-strict inequalities (e.g., )?
A: Adam Strzebonski (adams@wolfram.com) answers.
The package Algebra`InequalitySolve` (or Experimental`CylindricalAlgebraicDecomposition`) provides functionality for solving systems of inequalities.
![[Graphics:../Images/index_gr_79.gif]](../Images/index_gr_79.gif)
![[Graphics:../Images/index_gr_80.gif]](../Images/index_gr_80.gif)
![[Graphics:../Images/index_gr_81.gif]](../Images/index_gr_81.gif)
The function InequalityPlot, defined below, plots the two-dimensional region satisfying a set of polynomial inequalities in and with rational number coefficients.
![[Graphics:../Images/index_gr_84.gif]](../Images/index_gr_84.gif)
![[Graphics:../Images/index_gr_85.gif]](../Images/index_gr_85.gif)
![[Graphics:../Images/index_gr_86.gif]](../Images/index_gr_86.gif)
InequalityPlot could be extended to handle algebraic inequalities with algebraic number coefficients, and to plot lower-dimensional parts of the solution set, by using Experimental`CylindricalAlgebraicDecomposition instead of Experimental`GenericCylindricalAlgebraicDecomposition, and extending the cylinderplot code to handle lower-dimensional cylinders.
The region defined by the polynomial inequalities can now be visualized.
![[Graphics:../Images/index_gr_87.gif]](../Images/index_gr_87.gif)
![[Graphics:../Images/index_gr_88.gif]](../Images/index_gr_88.gif)
For optimization problems you can use Experimental`Minimize` or Experimental`Infimum`. Here are a few examples.
![[Graphics:../Images/index_gr_89.gif]](../Images/index_gr_89.gif)
![[Graphics:../Images/index_gr_90.gif]](../Images/index_gr_90.gif)
![[Graphics:../Images/index_gr_91.gif]](../Images/index_gr_91.gif)
![[Graphics:../Images/index_gr_92.gif]](../Images/index_gr_92.gif)
Since the first inequality is strict, the infimum is not attained in the set of points satisfying the constraints.
![[Graphics:../Images/index_gr_93.gif]](../Images/index_gr_93.gif)
![[Graphics:../Images/index_gr_94.gif]](../Images/index_gr_94.gif)
The computation of Infimum may be significantly faster than the computation of Minimize, especially if all constraints are strict inequalities.
Here is a more complicated example.
![[Graphics:../Images/index_gr_95.gif]](../Images/index_gr_95.gif)
![[Graphics:../Images/index_gr_96.gif]](../Images/index_gr_96.gif)
We visualize this minimum value, displayed as a point in the following graphic, by superimposing an InequalityPlot of on a ContourPlot of over .
![[Graphics:../Images/index_gr_100.gif]](../Images/index_gr_100.gif)
![[Graphics:../Images/index_gr_101.gif]](../Images/index_gr_101.gif)
Converted by Mathematica
May 8, 2000
[In and Out Index]
[Prev Page][Next Page] |