Optimization or Global Oprimization toolbox for semidefinite programming

7 ビュー (過去 30 日間)
Frogy Bo
Frogy Bo 2011 年 3 月 10 日
回答済み: TED MOSBY 2025 年 5 月 12 日
Hi all, just a quick question is it possible to use Optimization or Global Oprimization toolbox to solve semidefinite programming problem? I can't find the way to input semidefinite constraint for matrix. Thanks

回答 (1 件)

TED MOSBY
TED MOSBY 2025 年 5 月 12 日
Hi Frogy,
The Optimization Toolbox or Global Optimization Toolbox do not have a built-in solver that accepts a positive - semidefinite matix constraint. The conic solver that ships with MATLAB: "coneprog" used for second-order cones. Instead you can use a modelling layer that express variables as symmetric matrices, add the constraint X >= 0 (PSD), and call an external SDP solver.
For this you will have to download the following:
  • YALMIP: using YALMIP you describe the variables, constrainsts, cost etc.
  • SDP-capable solver like SDPT3 or SeDuMi: when you call "optimize", YALMIP packages your problem and hands it over to this solver that understands semi-definite problem.
Here is a little workflow showing how to get started:
  1. Use sdpvar just like you’d write variables on paper:
X = sdpvar(n,n,'symmetric'); % matrix you want PSD
2. Tell YALMIP the constraints and cost in plain math:
F = [X >= 0, trace(X) == 1]; % “X is PSD and its trace is 1”
cost = trace(C*X); % whatever you’re minimising
3. Pick a solver
ops = sdpsettings('solver','sdpt3'); % or 'sedumi', 'mosek', …
4. Then solve and record the answer
optimize(F, cost, ops);
Xopt = value(X);
Hope this helps!

カテゴリ

Help Center および File ExchangeProblem-Based Optimization Setup についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by