So I think I worked out a much faster solution. I will write the pseudo code and use your example
If you read the matrix formulation I proposed, what your code is doing is its most naive implementation. And yes, this is a very reasonable solution.
So I think I worked out a much faster solution. I will write the pseudo code and use your example
So I think I worked out a much faster solution.
[quote name='landagen' timestamp='1321906965' post='4886326']
So I think I worked out a much faster solution. I will write the pseudo code and use your example
[quote name='alvaro' timestamp='1321907485' post='4886332']
[quote name='landagen' timestamp='1321906965' post='4886326']
So I think I worked out a much faster solution. I will write the pseudo code and use your example
I think both will work just fine. In the case of sparse line compatibilities I think mine will consume less memory and will be faster, but yours will be quicker in the event of dense line compatibilities.
[/quote]
Well, I didn't propose a specific algorithm to compute the product of matrices I posted. Your pseudocode is a perfectly good way to do it. If the height is large, a dense matrix representation will work better. It might even be worth diagonalizing the matrix, so this method can be used.