#200 Nested BCRSMatrix gives wrong coldim
Metadata
Property | Value |
---|---|
Reported by | Markus Blatt (markus@dr-blatt.de) |
Reported at | Nov 20, 2006 10:03 |
Type | Bug Report |
Version | Git (pre2.4) [autotools] |
Operating System | Unspecified / All |
Closed by | Markus Blatt (markus@dr-blatt.de) |
Closed at | Nov 20, 2006 14:39 |
Closed in version | Unknown |
Resolution | Fixed |
Comment | Fixed with Revision 683 |
Description
Patrick Leidenberger mailed:
using the BCRSMatrix in a nested way shows me some problems:
I create a 4x4 BCRSMatrix of BCRSMatrices. Only in the second line and column I insert an object, lets say a 5x5 BCRSMatrix. If I look now at the construct, I get rowdim 10 and coldim 5: In the first row, second column exists an empty 5x5 Matrix, which I have not created! This problem can be avoid, if the empty diagonal elements in the 4x4 matrix are initialized with empty BCRSMatrices. If all elements in the 4x4 matrix are initialized with such empty matrices the total dimension of the matrix is 0x0! Perhaps this is a bug, if it isn't this behavior should be documented. I modified the dune-istl/istl/tutorial/example.cc to show the problem. The file is attached, this is the output: ============================================. E [n=5,m=5,rowdim=5,coldim=5] row 0 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 1 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 2 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 3 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 4 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 =============================================. ============================================. D [n=4,m=4,rowdim=10,coldim=5] row 0 . . . . . row 1 . . . . . row 2 . . . . . row 3 . . . . . row 4 . . . . . row 5 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 6 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 7 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 8 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 row 9 4.20e+01 4.20e+01 4.20e+01 4.20e+01 4.20e+01 =============================================.
The printmatrix function for this nested BCRSMatrices works fine. But is it possible to extend the writeMatrixToMatlab function so that it will works as well?
Regards Patrick