Skip to content
wangjie212Public

About

NCTSSOS is a non-commutative polynomial optimization tool based on the moment-SOHS hierarchy.

Resources

Stars

15 stars

Watchers

3 watching

Forks

Latest commit

 

History

78 Commits

Folders and files

Repository files navigation

NCTSSOS

NCTSSOS aims to provide a user-friendly and efficient tool for solving optimization problems with non-commutative/trace/state polynomials, which is based on the structured moment-SOHS hierarchy. To use NCTSSOS in Julia, run

pkg> add https://github.com/wangjie212/NCTSSOS
Documentation

Dependencies

NCTSSOS has been tested on Ubuntu and Windows.

Usage

Non-commutative polynomial optimization

Taking the objective $f=2-x_1^2+x_1x_2^2x_1-x_2^2$ and constraints $g=4-x_1^2-x_2^2\ge0$, $h=x_1x_2+x_2x_1-2=0$ as an example, to solve the first step of the NCTSSOS hierarchy, run

@ncpolyvar x[1:2]
f = 2 - x[1]^2 + x[1]*x[2]^2*x[1] - x[2]^2
ineq = [4 - x[1]^2 - x[2]^2]
eq = [x[1]*x[2] + x[2]*x[1] - 2]
pop = [f; ineq; eq]
d = 2 # set the relaxation order
opt,data = ncpop(pop, x, d, numeq=1, obj="eigen")

To solve higher steps of the NCTSSOS hierarchy, repeatedly run

opt,data = ncpop(data)

Options:
obj: "eigen" by default (perform eigenvalue minimization), "trace" (perform trace minimization)
CS: "MF" by default, false (invalidating correlative sparsity exploitation)
TS: "block" by default (maximal chordal extension), "MD" (approximately smallest chordal extension), false (invalidating term sparsity iterations)
partition: specify that the first partition variables commute with the remaining variables
comm_var: specify that the first comm_var variables commute each other
constraint: nothing by default or "projection" (satisfying $x_i^2=x_i$) or "unipotent" (satisfying $x_i^2=1$)

Trace polynomial optimization

Check out /examples/traceopt.jl.

State polynomial optimization

Check out /examples/stateopt.jl.

References

[1] Exploiting Term Sparsity in Noncommutative Polynomial Optimization, 2021.
[2] Sparse polynomial optimization: theory and practice, 2023.
[3] State polynomials: positivity, optimization and nonlinear Bell inequalities, 2023.

Contact

Jie Wang: wangjie212@amss.ac.cn

About

NCTSSOS is a non-commutative polynomial optimization tool based on the moment-SOHS hierarchy.

Resources

Stars

15 stars

Watchers

3 watching

Forks

Releases

Packages

Contributors

Languages