RE: [Algorithms] decompose onto non-orthogonal vectors
Brought to you by:
vexxed72
From: Tom F. <to...@mu...> - 2000-07-15 14:21:53
|
Throw one of the dimensions away (any one) - then you have only two equations. NOW can you solve it? :-) The third dimension will just give the same answer if p lies in the plane of a and b. If it isn't, then it's not a well-formed question, and you'll need another axis (c) to define a suitable basis. Then you have three dimensions and three unknowns, which you solve as you stated. Tom Forsyth - Muckyfoot bloke. Whizzing and pasting and pooting through the day. > -----Original Message----- > From: Klaus Hartmann [mailto:k_h...@os...] > Sent: 15 July 2000 15:01 > To: gda...@li... > Subject: Re: [Algorithms] decompose onto non-orthogonal vectors > > > > ----- Original Message ----- > From: Scott Justin Shumaker <sjs...@um...> > To: <gda...@li...> > Sent: Saturday, July 15, 2000 9:15 AM > Subject: Re: [Algorithms] decompose onto non-orthogonal vectors > > > > Okay, let me try and explain this as simply as possible. > You want to find > > scalars u,v such that u*a + v*b = p. Since these are 3-dimensional > > vectors, you have 3 equations and 2 unknowns: > > > > u*a1 + v*b1 = p1 > > u*a2 + v*b2 = p2 > > u*a3 + v*b3 = p3 > > > > where p1,p2,p3 are the coordinates of the point p, likewise > for a1,a2,a3 > > and a, and b1,b2,b3 and b. > > > > How do you solve a system of 3 linear equations with 2 > unknowns? If you > > don't know Gaussian elimination, this can be done with some simple > > algebraic rules and substituion. > > Okay, this may become very embarrassing for me now... :) How > can you solve a > system of 3 linear equations in two unknows, u, v, if they > cannot be reduced > to two linear equations (for example, a2 = a3, b2 = b3, and > p2 = p3)??? > > Let's assume that we change the 3 linear equations as follows: > > u*a1 + v*b1 + w*c1 = p1 > u*a2 + v*b2 + w*c2 = p2 > u*a3 + v*b3 + w*c3 = p3 > > Then there's a unique solution, if > > | a1 b1 c1 | > det | a2 b2 c2 | != 0 > | a3 b3 c3 | > > If we set c1 = c2 = c3 = 0, then we have the same system as > above (yours), > but with 3 unknowns: > > u*a1 + v*b1 + w*0 = p1 > u*a2 + v*b2 + w*0 = p2 > u*a3 + v*b3 + w*0 = p3 > > Then > | a1 b1 0 | > Dn = det | a2 b2 0 | = 0 > | a3 b3 0 | > > Since Dn = 0, we get a division by zero, and thus there's an > infinite number > of solutions. > > ... or did I just miss something??? > > Niki > > > > _______________________________________________ > GDAlgorithms-list mailing list > GDA...@li... > http://lists.sourceforge.net/mailman/listinfo/gdalgorithms-list > |