|
From: | Olaf Till |
Subject: | Re: A vectorization question |
Date: | Tue, 20 Dec 2011 11:10:31 +0100 |
User-agent: | Mutt/1.5.20 (2009-06-14) |
On Tue, Dec 20, 2011 at 05:53:10PM +0800, address@hidden wrote: > Is there a way of getting rid of this loop in > > for j=1:n > B(:,j)=c(j) * A(:,j); > endfor > > where c is a n-vector and A is a m by n matrix? B = A * diag (c);
[Prev in Thread] | Current Thread | [Next in Thread] |