# PolynomialSumOfSquaresList

PolynomialSumOfSquaresList[f,vars]

attempts to find polynomials with real coefficients {f1,,fn} such that f==f12++fn2.

# Details

• PolynomialSumOfSquaresList is typically used to show that a real polynomial is non-negative.
• f should be a polynomial in vars with real numeric coefficients.

# Examples

open allclose all

## Basic Examples(1)

Find a sum-of-squares representation of a polynomial:

A polynomial representable as a sum of squares is non-negative:

## Scope(6)

Find a sum-of-squares representation of a polynomial:

The polynomial is non-negative:

Find a sum-of-squares representation of a polynomial with exact real numeric coefficients:

Find a sum-of-squares representation of a polynomial with machine-precision real coefficients:

The difference of and the sum of squares has small coefficients:

Find a sum-of-squares representation of a polynomial with arbitrary-precision real coefficients:

The difference of and the sum of squares has arbitrary-precision zero coefficients:

A polynomial may not be representable as a sum of squares:

The polynomial attains negative values, hence it cannot be a sum of squares:

PolynomialSumOfSquaresList may fail even if a sum-of-squares representation exists:

## Applications(1)

Prove non-negativity of a large polynomial:

Compute a sum-of-squares representation:

is a sum of squares, hence it is non-negative:

FindInstance uses a method based on sum-of-squares representation here:

Deciding non-negativity of f using CylindricalDecomposition takes much more time:

## Properties & Relations(3)

A polynomial that has a sum-of-squares representation is non-negative:

Use FindInstance to show that is non-negative:

The Motzkin polynomial is non-negative, but is not a sum of squares:

Use Resolve to show that is non-negative:

Use MinValue to find the infimum of values of a polynomial:

PolynomialSumOfSquaresList fails for the non-negative polynomial :

PolynomialSumOfSquaresList succeeds for the strictly positive polynomial :

## Possible Issues(1)

PolynomialSumOfSquaresList may fail even if a sum-of-squares representation exists:

Wolfram Research (2021), PolynomialSumOfSquaresList, Wolfram Language function, https://reference.wolfram.com/language/ref/PolynomialSumOfSquaresList.html.

#### Text

Wolfram Research (2021), PolynomialSumOfSquaresList, Wolfram Language function, https://reference.wolfram.com/language/ref/PolynomialSumOfSquaresList.html.

#### CMS

Wolfram Language. 2021. "PolynomialSumOfSquaresList." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/PolynomialSumOfSquaresList.html.

#### APA

Wolfram Language. (2021). PolynomialSumOfSquaresList. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/PolynomialSumOfSquaresList.html

#### BibTeX

@misc{reference.wolfram_2024_polynomialsumofsquareslist, author="Wolfram Research", title="{PolynomialSumOfSquaresList}", year="2021", howpublished="\url{https://reference.wolfram.com/language/ref/PolynomialSumOfSquaresList.html}", note=[Accessed: 15-June-2024 ]}

#### BibLaTeX

@online{reference.wolfram_2024_polynomialsumofsquareslist, organization={Wolfram Research}, title={PolynomialSumOfSquaresList}, year={2021}, url={https://reference.wolfram.com/language/ref/PolynomialSumOfSquaresList.html}, note=[Accessed: 15-June-2024 ]}