smoghe
03-23-2005, 04:52 PM
Hello:
I am trying to solve a set of linear equations, Ax=B where A is 0 above the diagonal and A=27x27 in size. When I use SVD in MATLAB, I get reasonable solution for 'x'.
Define [U,W,V]=svd(A) in the usual sense.
The problem is that the 'U' computed in NR::C++ has elements with signs reversed (compared to Matlab). 'U' computed in C++ does give me 'U*U_transpose'=1.
Does anyone know how to overcome this problem ?
thank you.
Sachin
I am trying to solve a set of linear equations, Ax=B where A is 0 above the diagonal and A=27x27 in size. When I use SVD in MATLAB, I get reasonable solution for 'x'.
Define [U,W,V]=svd(A) in the usual sense.
The problem is that the 'U' computed in NR::C++ has elements with signs reversed (compared to Matlab). 'U' computed in C++ does give me 'U*U_transpose'=1.
Does anyone know how to overcome this problem ?
thank you.
Sachin