Path: news.mathworks.com!not-for-mail
From: "Sung Soo Kim" <sskimbox@aol.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Very weird resolution issue. Bug ????? Seriously !!
Date: Thu, 5 Mar 2009 13:18:02 +0000 (UTC)
Organization: JHU
Lines: 19
Message-ID: <goojea$d0a$1@fred.mathworks.com>
References: <goju5b$nv4$1@fred.mathworks.com> <muyocwgn8d7.fsf@G99-Boettcher.llan.ll.mit.edu> <gonnuu$krq$1@fred.mathworks.com> <goofma$4m6$1@fred.mathworks.com> <goohnt$j76$1@fred.mathworks.com>
Reply-To: "Sung Soo Kim" <sskimbox@aol.com>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1236259082 13322 172.30.248.35 (5 Mar 2009 13:18:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 5 Mar 2009 13:18:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1724905
Xref: news.mathworks.com comp.soft-sys.matlab:522716

Now I'm just curious. (not offending, not raising an issue, not making any claim, not protesting)

In my original example shown below, the result is '0'. What kind of algorithm do you guess is used in each multiplication (one in vector, and the other in matrix)? I'm out of EE field for a long time (like almost a decade). I'm just curious of what the optimization algorithm is and what the advantage is (besides speed).

x = [
    1 1
    0 0
    0 0
    0 0
    0 0
    0 0
    0 0];

a = bsxfun(@minus,x,mean(x));

b=a'*a; c=a(:,1)'*a(:,1);
isequal(c,b(1,1))

% As a reminder, if x=[0 0;0 0;0 0;0 0;0 0;0 0;1 1]; is used, then the result is '1'.