Registered Member
|
I probably found a bug:
Vector2=something; Vector1 = Vector2; the solution of vec = sparse_mat.transpose() * Vector1 is right. vec = sparse_mat.transpose() * (Vector1+Vector2)*0.5 is wrong.
Last edited by Seb on Fri Feb 20, 2009 5:14 pm, edited 1 time in total.
|
Moderator
|
do you have a complete test code because I cannot reproduce the bug
|
Registered Member
|
Yes!
|
Moderator
|
sorry, but I cannot reproduce the issue. Actually your example is not helping much, what is TVector ? how is declared global_stiffness_matrix ? etc.
|
Registered Member
|
The data types are default VectorXd and SparseMatrix . But I found the origin: The input vector contained uninitialized values. I did not really discover the location of the programming error, but will look into that later. Funny that there are two different solutions. But no wonder that they were wrong...
|
Registered users: Bing [Bot], Evergrowing, Google [Bot], rblackwell