source:
proiecte/pmake3d/make3d_original/Make3dSingleImageStanford_version0.1/third_party/opt/yalmip/extras/@ncvar/shiftdim.m
@
37
Last change on this file since 37 was 37, checked in by , 14 years ago | |
---|---|
File size: 427 bytes |
Line | |
---|---|
1 | function [X,n] = shiftdim(varargin) |
2 | % SHIFTDIM (overloaded) |
3 | |
4 | % Author Johan Löfberg |
5 | % $Id: shiftdim.m,v 1.1 2006/08/10 18:00:22 joloef Exp $ |
6 | |
7 | Y = varargin{1}; |
8 | X = Y; |
9 | X.basis = []; |
10 | for i = 1:size(Y.basis,2) |
11 | base = reshape(full(Y.basis(:,i)),[X.dim(1) X.dim(2)]); |
12 | [base,n] = shiftdim(base,varargin{2:end}); |
13 | X.basis = [X.basis sparse(base(:))]; |
14 | end |
15 | [X.dim(1), X.dim(2)] = size(base); |
16 | X.conicinfo = [0 0]; |
17 | X = clean(X); |
Note: See TracBrowser
for help on using the repository browser.