solveSOS(f)
solveSOS(f,objFun)
This method solves sums-of-squares problems. Given a rational (or real) polynomial $f(x)$, it attempts to find a rational (or real) positive semidefinite matrix $Q$ and a vector of monomials $mon$ such that $$f(x) = mon' Q mon.$$ The algorithm first computes a floating point solution, and then tries to obtain an exact solution by rounding the numerical result. If the rounding fails, the numerical solution is returned.
|
|
|
|
|
|
SOS with parameters: If the coefficients of the polynomial are linearly parametrized, we can search for parameters which render a polynomial to be a sum of squares. In the following example, the variable $t$ will be treated as a free parameter.
|
|
|
|
|
It is possible to solve sums-of-squares problems with several parameters. In the following example we increase two of the coefficients of the Robinson polynomial until it becomes a sum of squares.
|
|
|
|
SOS with parameter optimization: The method also allows to optimize a linear function of the parameters. More precisely, given a polynomial $f(x;p)$ that depends affinely on some parameters $p$, we can solve the problem
$$min_{p} \, objFun(p) \,\,\, s.t. \,\,\, f(x; p) \, is SOS $$
In the following example we minimize $-t$ in order to find a lower bound for the polynomial $x^2-3x$:
|
|
|
|
By default the method tries to obtain rational values of the parameters. Since there is a trade-off between rounding and optimality, we specify the rounding precision as an optional input argument.
The object solveSOS is a method function with options.