source: proiecte/pmake3d/make3d_original/Make3dSingleImageStanford_version0.1/third_party/opt/yalmip/@sdpvar/toeplitz.m @ 37

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

Added original make3d

File size: 602 bytes
Line 
1function t = toeplitz(c,r)
2%TOEPLITZ (overloaded)
3
4% Author Johan Löfberg
5% $Id: toeplitz.m,v 1.5 2006/02/05 13:21:29 joloef Exp $
6
7% direct 1-to-1 copy of MATLAB double code
8if nargin < 2,
9    c.basis(1,:) = conj(c.basis(1,:));
10    r = c;
11    c.basis = conj(c.basis);
12    %  c(1) = conj(c(1));
13    %  r = c;
14    %  c = conj(c);
15end
16r = reshape(r,prod(size(r)),1);%r(:)
17p = length(r);
18m = length(c);
19x = [extsubsref(r,p:-1:2) ; reshape(c,prod(size(c)),1)];
20cidx = (0:m-1)';
21ridx = p:-1:1;
22t = cidx(:,ones(p,1)) + ridx(ones(m,1),:);
23t = extsubsref(x,t);
24if isa(t,'sdpvar')
25    t.conicinfo = [0 0];
26end
27
Note: See TracBrowser for help on using the repository browser.