⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 check.m

📁 半定规划
💻 M
字号:
%*****************************************************************************% DSDP5:  Dual-Scaling Algorithm for Positive Semidefinite Programming% Copyright (c) 2004 by% S. J. Benson, Y. Ye% Last modified: 20 October 2004%*****************************************************************************% check;%% This script tests the DSDP solver using the examples. Compare the output% to the file check.out% diary on;ntrials=2;BB=cell(1);for trials = [1:ntrials];  N = 10;  B = zeros(N);   for i=1:N,    for j=1:N, B(i,j)=mod(i+j,trials+1); end;  end;  fprintf('MAXCUT \n');  [y,X,obj] = maxcut(B);   fprintf('GPP \n');  [y,X,obj] = gpp(B,1);   fprintf('ETP \n');  [obj,d]=etp(B*B'+speye(N)');  fprintf('THETA\n');  [obj,X]=thetaproblem(B);end;%[X,y] = randdinf([10 4 3], 20);OPTIONS=doptions;OPTIONS.print=10;fprintf('CONTROL1\n');[AC,b] = readsdpa('control1.dat-s');[STAT,y,X]=dsdp(b,AC,OPTIONS);fprintf('ARCH0\n');[AC,b] = readsdpa('arch0.dat-s');[STAT,y,X]=dsdp(b,AC,OPTIONS);diary off;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -