comparison solvers/SMALL_cgp.m @ 62:92a9b18c3bd3

(none)
author idamnjanovic
date Tue, 15 Mar 2011 12:23:25 +0000
parents 524cc3fff5ac
children fb32456fba2c
comparison
equal deleted inserted replaced
61:42fcbcfca132 62:92a9b18c3bd3
34 Dt =@(z) Dict'*z; 34 Dt =@(z) Dict'*z;
35 elseif isa(Dict,'function_handle') 35 elseif isa(Dict,'function_handle')
36 try 36 try
37 DictT=varargin{1}; 37 DictT=varargin{1};
38 if isa(DictT,'function_handle'); 38 if isa(DictT,'function_handle');
39 D=Dict; 39 D=@(z)Dict(z,1);
40 Dt=DictT; 40 Dt=@(z)Dict(z,2);
41 else 41 else
42 error('If Dictionary is a function handle,Transpose Dictionary also needs to be a function handle. '); 42 error('If Dictionary is a function handle,Transpose Dictionary also needs to be a function handle. ');
43 end 43 end
44 catch 44 catch
45 error('If Dictionary is a function handle, Transpose Dictionary needs to be specified. Exiting.'); 45 error('If Dictionary is a function handle, Transpose Dictionary needs to be specified. Exiting.');
46 end 46 end
47 else 47 else
48 error('Dictionary is of unsupported type. Use explicit matrix, function_handle or object. Exiting.'); 48 error('Dictionary is of unsupported type. Use explicit matrix, function_handle or object. Exiting.');
49 end 49 end
50 %% 50 %%
51 positivity=1; 51 %positivity=1;
52 [n,P]=size(X); 52 [n,P]=size(X);
53 53
54 54
55 55
56 A = sparse(m,size(X,2)); 56 A = sparse(m,size(X,2));