Prev: INTERPOLATION & ELLIPSE FORMATION
Next: ahhhhh....help!
From: atanas on 26 Apr 2010 20:07 "Roger Stafford" <ellieandrogerxyzzy(a)mindspring.com.invalid> wrote in message <hr4is8$9cc$1(a)fred.mathworks.com>... > "atanas " <atanaslove2000(a)abv.bg> wrote in message <hqvsda$m6d$1(a)fred.mathworks.com>... > > Hello, > > I have problem for my project: > > Let we matrices C0,C1,C2,C3,D0,D1,D2, and D3 are with size 2x2. > > We knowing matrices C0,C1,C2,and C3 that > > [C0 C1 C2 C3]*[C0 C1 C2 C3]'=I > > We construct the matrix > > W=[C0 C1 C2 C3 zeros(2,2) zeros(2,2); > > zeros(2,2) zeros(2,2) C0 C1 C2 C3; > > D0 D1 D2 D3 zeros(2,2) zeros(2,2); > > zeros(2,2) zeros(2,2) D0 D1 D2 D3]. > > > > How to find matrix D0,D1,D2, and D3 so that satisfy condition W*W'=I? > ----------------- > Atanas, this thread is stretching out too long, so in spite of what I said earlier, I have decided to give you my version of a matlab code that would solve your problem. I hope you will find it useful. I leave it up to you to discover the logic behind the algorithm. > > Remember, it is very important that any set of C0, C1, C2, C3 you create yourself instead of using part 1 should pass the test that is given there with just as much accuracy as in part 1, namely with errors only out in the 14th or 15th decimal place. Otherwise the procedure in part 2 will not be accurate. It depends on the C's being correctly chosen. > > If you recall, I mentioned earlier that there is one degree of freedom in the choice of the D's, for any given set of C's. In the code below in the line > > y = null([y1,y2])'; > > matlab's 'null' function must choose two normal mutually orthogonal four-element vectors which are orthogonal to y1 and y2, so it must choose them in a two-dimensional subspace. However, the two vectors could be at any rotated orientation in this subspace and this is where the one degree of freedom for the D's comes in. > > Roger Stafford > -------------------------- > % Part 1 - Random generation of C's > clear > x = orth(randn(4))'; > y = orth(randn(4,2))'; > C0 = y(:,1:2)*x(1:2,1:2); > C1 = y(:,1:2)*x(1:2,3:4); > C2 = y(:,3:4)*x(3:4,1:2); > C3 = y(:,3:4)*x(3:4,3:4); > > % Check the C's > Z2 = zeros(2); > V = [C0,C1,C2,C3,Z2,Z2; > Z2,Z2,C0,C1,C2,C3]; > format long > disp(max(max(abs(V*V'-eye(4))))) > clear V Z2 x y > > % Part 2 - Given the proper C's, create D's > x1 = orth([C0,C1]')'; > x2 = orth([C2,C3]')'; > y1 = [C0,C1]/x1; > y2 = [C2,C3]/x2; > y = null([y1,y2])'; > D0 = y(:,1:2)*x1(:,1:2); > D1 = y(:,1:2)*x1(:,3:4); > D2 = y(:,3:4)*x2(:,1:2); > D3 = y(:,3:4)*x2(:,3:4); > > % Check the D's > Z2 = zeros(2); > W = [C0,C1,C2,C3,Z2,Z2; > Z2,Z2,C0,C1,C2,C3; > D0,D1,D2,D3,Z2,Z2; > Z2,Z2,D0,D1,D2,D3]; > format long > disp(max(max(abs(W*W'-eye(8))))) > clear W Z2 x1 x2 y y1 y2 > -------------------------- Thank you very much. This is original solution for me. I have to study more a linear algebra. You are very good teacher. Thanks again. Best regards.
From: atanas on 26 Apr 2010 20:09 "Roger Stafford" <ellieandrogerxyzzy(a)mindspring.com.invalid> wrote in message <hr4is8$9cc$1(a)fred.mathworks.com>... > "atanas " <atanaslove2000(a)abv.bg> wrote in message <hqvsda$m6d$1(a)fred.mathworks.com>... > > Hello, > > I have problem for my project: > > Let we matrices C0,C1,C2,C3,D0,D1,D2, and D3 are with size 2x2. > > We knowing matrices C0,C1,C2,and C3 that > > [C0 C1 C2 C3]*[C0 C1 C2 C3]'=I > > We construct the matrix > > W=[C0 C1 C2 C3 zeros(2,2) zeros(2,2); > > zeros(2,2) zeros(2,2) C0 C1 C2 C3; > > D0 D1 D2 D3 zeros(2,2) zeros(2,2); > > zeros(2,2) zeros(2,2) D0 D1 D2 D3]. > > > > How to find matrix D0,D1,D2, and D3 so that satisfy condition W*W'=I? > ----------------- > Atanas, this thread is stretching out too long, so in spite of what I said earlier, I have decided to give you my version of a matlab code that would solve your problem. I hope you will find it useful. I leave it up to you to discover the logic behind the algorithm. > > Remember, it is very important that any set of C0, C1, C2, C3 you create yourself instead of using part 1 should pass the test that is given there with just as much accuracy as in part 1, namely with errors only out in the 14th or 15th decimal place. Otherwise the procedure in part 2 will not be accurate. It depends on the C's being correctly chosen. > > If you recall, I mentioned earlier that there is one degree of freedom in the choice of the D's, for any given set of C's. In the code below in the line > > y = null([y1,y2])'; > > matlab's 'null' function must choose two normal mutually orthogonal four-element vectors which are orthogonal to y1 and y2, so it must choose them in a two-dimensional subspace. However, the two vectors could be at any rotated orientation in this subspace and this is where the one degree of freedom for the D's comes in. >
From: atanas on 26 Apr 2010 20:40 "atanas " <atanaslove2000(a)abv.bg> wrote in message <hr59r8$gcm$1(a)fred.mathworks.com>... > "Roger Stafford" <ellieandrogerxyzzy(a)mindspring.com.invalid> wrote in message <hr4is8$9cc$1(a)fred.mathworks.com>... > > "atanas " <atanaslove2000(a)abv.bg> wrote in message <hqvsda$m6d$1(a)fred.mathworks.com>... > > > Hello, > > > I have problem for my project: > > > Let we matrices C0,C1,C2,C3,D0,D1,D2, and D3 are with size 2x2. > > > We knowing matrices C0,C1,C2,and C3 that > > > [C0 C1 C2 C3]*[C0 C1 C2 C3]'=I > > > We construct the matrix > > > W=[C0 C1 C2 C3 zeros(2,2) zeros(2,2); > > > zeros(2,2) zeros(2,2) C0 C1 C2 C3; > > > D0 D1 D2 D3 zeros(2,2) zeros(2,2); > > > zeros(2,2) zeros(2,2) D0 D1 D2 D3]. > > > > > > How to find matrix D0,D1,D2, and D3 so that satisfy condition W*W'=I? > > ----------------- > > Atanas, this thread is stretching out too long, so in spite of what I said earlier, I have decided to give you my version of a matlab code that would solve your problem. I hope you will find it useful. I leave it up to you to discover the logic behind the algorithm. > > > > Remember, it is very important that any set of C0, C1, C2, C3 you create yourself instead of using part 1 should pass the test that is given there with just as much accuracy as in part 1, namely with errors only out in the 14th or 15th decimal place. Otherwise the procedure in part 2 will not be accurate. It depends on the C's being correctly chosen. > > > > If you recall, I mentioned earlier that there is one degree of freedom in the choice of the D's, for any given set of C's. In the code below in the line > > > > y = null([y1,y2])'; > > > > matlab's 'null' function must choose two normal mutually orthogonal four-element vectors which are orthogonal to y1 and y2, so it must choose them in a two-dimensional subspace. However, the two vectors could be at any rotated orientation in this subspace and this is where the one degree of freedom for the D's comes in.
From: atanas on 26 Apr 2010 20:47
"atanas " <atanaslove2000(a)abv.bg> wrote in message <hr59v0$ner$1(a)fred.mathworks.com>... > "Roger Stafford" <ellieandrogerxyzzy(a)mindspring.com.invalid> wrote in message <hr4is8$9cc$1(a)fred.mathworks.com>... > > "atanas " <atanaslove2000(a)abv.bg> wrote in message <hqvsda$m6d$1(a)fred.mathworks.com>... > > > Hello, > > > I have problem for my project: > > > Let we matrices C0,C1,C2,C3,D0,D1,D2, and D3 are with size 2x2. > > > We knowing matrices C0,C1,C2,and C3 that > > > [C0 C1 C2 C3]*[C0 C1 C2 C3]'=I > > > We construct the matrix > > > W=[C0 C1 C2 C3 zeros(2,2) zeros(2,2); > > > zeros(2,2) zeros(2,2) C0 C1 C2 C3; > > > D0 D1 D2 D3 zeros(2,2) zeros(2,2); > > > zeros(2,2) zeros(2,2) D0 D1 D2 D3]. > > > > > > How to find matrix D0,D1,D2, and D3 so that satisfy condition W*W'=I? > > ----------------- > > Atanas, this thread is stretching out too long, so in spite of what I said earlier, I have decided to give you my version of a matlab code that would solve your problem. I hope you will find it useful. I leave it up to you to discover the logic behind the algorithm. > > > > Remember, it is very important that any set of C0, C1, C2, C3 you create yourself instead of using part 1 should pass the test that is given there with just as much accuracy as in part 1, namely with errors only out in the 14th or 15th decimal place. Otherwise the procedure in part 2 will not be accurate. It depends on the C's being correctly chosen. > > > > If you recall, I mentioned earlier that there is one degree of freedom in the choice of the D's, for any given set of C's. In the code below in the line > > > > y = null([y1,y2])'; > > > > matlab's 'null' function must choose two normal mutually orthogonal four-element vectors which are orthogonal to y1 and y2, so it must choose them in a two-dimensional subspace. However, the two vectors could be at any rotated orientation in this subspace and this is where the one degree of freedom for the D's comes in. > > Sir R. Stafford, I don't know for now, but continue calculate and research this method. If you have anywhere similar book, please send me! For future , if have good results I send you mail. Thank again. |