Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: one to many mapping matrix
Date: Wed, 29 Sep 2010 03:32:19 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 39
Message-ID: <i7uc03$70u$1@fred.mathworks.com>
References: <i7u8ku$1h2$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1285731139 7198 172.30.248.35 (29 Sep 2010 03:32:19 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Wed, 29 Sep 2010 03:32:19 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1187260
Xref: news.mathworks.com comp.soft-sys.matlab:674074

"Kate " <chino_tones@hotmail.com> wrote in message <i7u8ku$1h2$1@fred.mathworks.com>...
> Hi guys,
> 
> Asking for a bit of help.
> 
> I have a matrix :
> 
> Matrix =  [  100   200   300   400
>                 500   400   600    700
>                 800   900   500   200]
> 
> I basically want to form a new matrix that looks like:
> 
> New_Matrix = [ 500  400  300   400
>                       800  900  300    400
>                       100  200   600   700
>                       800  900   600   700
>                       100  200   500   200
>                       500  400   500   200]
> 
> So basically :
> 
> in 'Matrix' ,  {300 400} maps to {500 400} & { 800 900}
> similarly,      {600  700} maps to {100 200) & {800  900}
> and,           {500  200}  maps to {100 200} & {500 400}
> 
> 
> I'd like to be able to get some help in creating a solution to form  the "New_Matrix".
> Please note that in my dataset , the input data , i.e. "Matrix", has potential to be large , so my code can't be limited to the example "Matrix" I used here.
> 
> thanks
> kate
- - - - - - - -
  When it comes to larger matrices, you need to explain how your "mapping' generalizes.  Do you always have four columns or is the number of columns even?  Do you care about the order of rows in New_Matrix?  If your matrix has n rows, will New_Matrix always have n*(n-1) rows?  Questions of that kind.

  And finally can you show us what you have already done to solve this problem?  Providing you help should not be the same thing as doing it all for you in a tidy package.

Roger Stafford