lars
PURPOSE 
The dimension is p^2 (thus w
SYNOPSIS 
function [y]=lars(p,ind,mat,rhs,n,d,smin,h,i0,j0)
DESCRIPTION 
CROSS-REFERENCE INFORMATION 
This function calls:
- dot Dot product of two QTT-Tuckers
- dot Frobenius dot product of two TT-matrices
- dot Dot product of two TT tensors
- reshape Reshape of the TT-tensor
This function is called by:
SOURCE CODE 
0001
0002 function [y]=lars(p,ind,mat,rhs,n,d,smin,h,i0,j0)
0003
0004 k0=p*p;
0005 x=zeros(k0,1);
0006 pp=2.^(0:d-1);
0007 for i=1:k0
0008 ix=ind(d*(i-1)+1:d*i);
0009 ix=dot((ix-1),pp);
0010 x(i)=smin+h*ix;
0011 end
0012 mm=x(1)*mat{1};
0013 for i=2:numel(mat)
0014 mm=mm+x(i)*mat{i};
0015 end
0016 sol=mm \ rhs;
0017 sol=reshape(sol,n,n);
0018 y=sol(i0,j0);
0019 return
0020 end
Generated on Wed 08-Feb-2012 18:20:24 by m2html © 2005