i1 : R = QQ[x,y]; |

i2 : f = 2*x^4+5*y^4-2*x^2*y^2+2*x^3*y; |

i3 : sol = solveSOS f; Executing CSDP Input file: /tmp/M2-2709-0/4.dat-s Output file: /tmp/M2-2709-0/5 Status: SDP solved, primal-dual feasible Start rational rounding |

i4 : s = sosPoly sol o4 = coeffs: 43 231773 {5, --, ------} 20 344000 gens: 83 2 2 20 2 2 {- ---x + y , --x + x*y, x } 200 43 o4 : SOSPoly |

i5 : sumSOS(s) 4 3 2 2 4 o5 = 2x + 2x y - 2x y + 5y o5 : R |

i6 : R = QQ[x,y]; |

i7 : S = R/ideal(x^2 + y^2 - 1); |

i8 : f = 10-x^2-y; |

i9 : sol = solveSOS (f, 2); Executing CSDP Input file: /tmp/M2-2709-0/8.dat-s Output file: /tmp/M2-2709-0/9 Status: SDP solved, primal-dual feasible Start rational rounding |

i10 : sosPoly sol o10 = coeffs: 83 {7, 6, --} 28 gens: 1 {y - --, x, 1} 14 o10 : SOSPoly |

- The package implements Hilbert's algorithm to decompose a nonnegative ternary form into a sum-of-squares of rational functions: sosdecTernary
- Sums of squares problems can be solved parametrically: solveSOS
- Optimization over varieties can run using lowerBound

- [BPT12]
*Semidefinite Optimization and Convex Algebraic Geometry*SIAM Textbook, edited by G. Blekherman, P. Parrilo, and R. Thomas, (2012) - [P05]
*Exploiting Algebraic Structure in Sum of Squares Programs*P. Parrilo in*Positive polynomials in control*(2005) - [PP]
*Computing sum-of-squares decompositions with rational coefficients*H. Peyrl and P. Parrilo in Theoretical Computer Science 409 (2008) p. 269–281

- Special thanks: Ilir Dema, Nidhi Kaihnsa, Anton Leykin

- Functions and commands
- checkSolver -- tests an SDP solver
- library -- library of interesting nonnegative forms
- lowerBound -- finds a lower bound for a polynomial
- recoverSolution -- Factor a rank one PSD matrix
- solveSOS -- solve a sum-of-squares problem
- sosdecTernary -- Sum of squares decomposition for ternary forms.
- sosInIdeal -- Sum of squares polynomial in ideal
- sosPoly -- make an SOS polynomial
- sumSOS -- expansion of a weighted SOS decomposition

- Methods
- clean(RR,SOSPoly) -- Remove terms with very small coefficients from a sum-of-squares.
- recoverSolution(SDPResult), see recoverSolution -- Factor a rank one PSD matrix
- net(SDPResult), see SDPResult -- result of an SDP computation
- coefficients(SOSPoly), see SOSPoly -- A type to store SOS decompositions of polynomials
- generators(SOSPoly), see SOSPoly -- A type to store SOS decompositions of polynomials
- length(SOSPoly), see SOSPoly -- A type to store SOS decompositions of polynomials
- Matrix == SOSPoly, see SOSPoly -- A type to store SOS decompositions of polynomials
- net(SOSPoly), see SOSPoly -- A type to store SOS decompositions of polynomials
- Number * SOSPoly, see SOSPoly -- A type to store SOS decompositions of polynomials
- ring(SOSPoly), see SOSPoly -- A type to store SOS decompositions of polynomials
- RingElement == SOSPoly, see SOSPoly -- A type to store SOS decompositions of polynomials
- SOSPoly * SOSPoly, see SOSPoly -- A type to store SOS decompositions of polynomials
- SOSPoly + SOSPoly, see SOSPoly -- A type to store SOS decompositions of polynomials
- SOSPoly == Matrix, see SOSPoly -- A type to store SOS decompositions of polynomials
- SOSPoly == RingElement, see SOSPoly -- A type to store SOS decompositions of polynomials
- SOSPoly == SOSPoly, see SOSPoly -- A type to store SOS decompositions of polynomials
- SOSPoly ^ ZZ, see SOSPoly -- A type to store SOS decompositions of polynomials
- substitute(SOSPoly,Ring), see SOSPoly -- A type to store SOS decompositions of polynomials
- sosPoly(SDPResult), see sosPoly -- make an SOS polynomial
- sumSOS(SOSPoly), see sumSOS -- expansion of a weighted SOS decomposition