comparison Problems/private/collincomb.m @ 10:207a6ae9a76f version1.0

(none)
author idamnjanovic
date Mon, 22 Mar 2010 15:06:25 +0000
parents
children
comparison
equal deleted inserted replaced
9:28f2b5fe3483 10:207a6ae9a76f
1 %COLLINCOMB Linear combination of matrix columns.
2 % Y = COLLINCOMB(A,COLS,X) computes a linear combination of the columns of
3 % the matrix A. The column indices are specified in the vector COLS, and
4 % the correspoinding coefficients are specified in the vector X. The
5 % vectors COLS and X must be of the same length.
6 %
7 % The call Y = COLLINCOMB(A,COLS,X) is essentially equivalent to
8 %
9 % Y = A(:,COLS)*X .
10 %
11 % However, it is implemented much more efficiently.
12 %
13 % Y = COLLINCOMB(A,ROWS,COLS,X) only works on the rows of A specified
14 % in ROWS, returning a vector of length equal to ROWS. This call is
15 % essentially equivalent to the command
16 %
17 % Y = A(ROWS,COLS)*X .
18 %
19 % See also ROWLINCOMB.
20
21
22 % Ron Rubinstein
23 % Computer Science Department
24 % Technion, Haifa 32000 Israel
25 % ronrubin@cs
26 %
27 % April 2009