source: proiecte/pmake3d/make3d_original/Make3dSingleImageStanford_version0.1/third_party/opt/yalmip/dev/tests-mbg/mpt/mpt_paramcost_1.m @ 37

Last change on this file since 37 was 37, checked in by (none), 14 years ago

Added original make3d

File size: 594 bytes
Line 
1function mpt_paramcost_1
2
3B = [-1  1  1  1  0  0  0  0  0  0;
4      1  0  0  0  1 -1  1  0  0  0;
5      0 -1  0  0  0  0  0  1 -1  1;
6      0  0 -1  0 -1  1  0 -1  1  0
7      0  0  0 -1  0  0 -1  0  0 -1]
8
9c = [3.1 2.3 1.2  12.3 2.5 9.6 2.1 6.8 2.1 2.2]';
10d = [4.2 7.4 14.7 9.7  1.0 3.1 5.1 2.2 5.9 6.7]';
11b = [size(B,1)-1;-ones(4,1)];
12
13t = sdpvar(1,1);
14x = sdpvar(10,1);
15F = set(0 <= t <= 1) + set(B*x == b) + set(0 <= x <= 10)
16
17[SOL, DIAGNOSTIC,Z,HPWF,ZPWF] = solvemp(F,(t*c+(1-t)*d)'*x,sdpsettings('debug',1),t)
18
19assign(t,0.38);
20cost = double(HPWF);
21
22mbg_asserttolequal(cost,43.8,0.0001);
23
24
Note: See TracBrowser for help on using the repository browser.