http://www.mathworks.com/matlabcentral/newsreader/view_thread/306341
MATLAB Central Newsreader  Solving a Overdeterminated System  More Equantions than unknows
Feed for thread: Solving a Overdeterminated System  More Equantions than unknows
enus
©19942014 by MathWorks, Inc.
webmaster@mathworks.com
MATLAB Central Newsreader
http://blogs.law.harvard.edu/tech/rss
60
MathWorks
http://www.mathworks.com/images/membrane_icon.gif

Fri, 15 Apr 2011 22:55:05 +0000
Solving a Overdeterminated System  More Equantions than unknows
http://www.mathworks.com/matlabcentral/newsreader/view_thread/306341#831390
Carlos Junior
Hi,<br>
<br>
I would like, please, a help to solve a system with 12 equations and 9 unknows. Is there some way ? <br>
<br>
The system of equations :<br>
<br>
[296 199 1]' = H * [0.1 0.1 1]' <br>
[367 210 1]' = H * [0.2 0.1 1]' <br>
[273 267 1]' = H * [0.1 0.2 1]' <br>
[346 281 1]' = H * [0.2 0.2 1]' <br>
<br>
The unknows are the nine elements from H matrix .<br>
<br>
Observation:<br>
To solve H only for one group, I could use "pinv" command , but , what about the 4 groups shown above together ?!<br>
Example to solve H for only one group (3 equations, 9 unknows )!<br>
[296 199 1]' = H * [0.1 0.1 1]' <br>
H = [296 199 1]' * pinv ( [0.1 0.1 1]' )<br>
H = 29.0196 29.0196 290.1961<br>
19.5098 19.5098 195.0980<br>
0.0980 0.0980 0.9804<br>
<br>
Very Thanks ,<br>
<br>
Carlos <br>
carlosjunior@gmail.com

Sat, 16 Apr 2011 02:24:40 +0000
Re: Solving a Overdeterminated System  More Equantions than unknows
http://www.mathworks.com/matlabcentral/newsreader/view_thread/306341#831395
Nasser M. Abbasi
On 4/15/2011 3:55 PM, Carlos Junior wrote:<br>
> Hi,<br>
><br>
> I would like, please, a help to solve a system with 12 equations and 9 unknows. Is there some way ?<br>
<br>
Why not simply A\b ? This will give you least squares solution.<br>
<br>
Nasser

Sat, 16 Apr 2011 14:35:05 +0000
Re: Solving a Overdeterminated System  More Equantions than unknows
http://www.mathworks.com/matlabcentral/newsreader/view_thread/306341#831447
Carlos Junior
Hi Nasser,<br>
Thanks by the attention, but I did not understand your solution... I tried now to apply that at MatLab and it did not work ! <br>
<br>
My necessity is to solve the system below (to find H) :<br>
<br>
IMPORTANT : H is a 3x3 matrix. Thus, I have nine unknows.<br>
<br>
H = [ h11 h12 h13 ; h21 h22 h23 ; h31 h32 h33 ]<br>
<br>
[296 199 1]' = H * [0.1 0.1 1]'<br>
[367 210 1]' = H * [0.2 0.1 1]'<br>
[273 267 1]' = H * [0.1 0.2 1]'<br>
[346 281 1]' = H * [0.2 0.2 1]' <br>
<br>
How should I use your proposition A\b ? <br>
<br>
Thanks,<br>
<br>
Carlos<br>
carlosjunior@gmail.com<br>
<br>
<br>
"Nasser M. Abbasi" <nma@12000.org> wrote in message <ioaulj$fek$1@speranza.aioe.org>...<br>
> On 4/15/2011 3:55 PM, Carlos Junior wrote:<br>
> > Hi,<br>
> ><br>
> > I would like, please, a help to solve a system with 12 equations and 9 unknows. Is there some way ?<br>
> <br>
> Why not simply A\b ? This will give you least squares solution.<br>
> <br>
> Nasser

Sat, 16 Apr 2011 17:51:05 +0000
Re: Solving a Overdeterminated System  More Equantions than unknows
http://www.mathworks.com/matlabcentral/newsreader/view_thread/306341#831474
Roger Stafford
"Carlos Junior" <carlosjunior@gmail.com> wrote in message <ioc9ep$d1f$1@fred.mathworks.com>...<br>
> Hi Nasser,<br>
> Thanks by the attention, but I did not understand your solution... I tried now to apply that at MatLab and it did not work ! <br>
> <br>
> My necessity is to solve the system below (to find H) :<br>
> <br>
> IMPORTANT : H is a 3x3 matrix. Thus, I have nine unknows.<br>
> <br>
> H = [ h11 h12 h13 ; h21 h22 h23 ; h31 h32 h33 ]<br>
> <br>
> [296 199 1]' = H * [0.1 0.1 1]'<br>
> [367 210 1]' = H * [0.2 0.1 1]'<br>
> [273 267 1]' = H * [0.1 0.2 1]'<br>
> [346 281 1]' = H * [0.2 0.2 1]' <br>
> <br>
> How should I use your proposition A\b ? <br>
> <br>
> Thanks,<br>
> <br>
> Carlos<br>
> carlosjunior@gmail.com<br>
        <br>
I think what Nasser has indicated to you is that you are trying to "solve" the matrix equation<br>
<br>
H*A = b<br>
<br>
where H is a 3 x 3 matrix of unknowns with<br>
<br>
A = [0.1 0.2 0.1 0.2;<br>
0.1 0.1 0.2 0.2;<br>
1 1 1 1];<br>
<br>
and<br>
<br>
b = [296 367 273 346;<br>
199 210 267 281;<br>
1 1 1 1];<br>
<br>
As you have stated this involves 12 equations but only 9 unknowns so it cannot actually be solved. However matlab's 'slash' operator is designed to give the least squares approximation to it:<br>
<br>
H = b/A<br>
<br>
Notice that it is analogous to doing a right multiply by the inverse of A, though A's size is 3 x 4 and cannot have an actual inverse. Similar statements can be made about the 'backslash' operator.<br>
<br>
Notice also that each of the three rows of H represent an independent set of 4 equations and 3 unknowns. You could have applied least squares analysis to each set separately.<br>
<br>
Roger Stafford