in reply to Strassen's Algorithm for Matrix Multiplication

Porting the C-code in WP:Strassen_algorithm#Source_code seems straightforward!

Don't you think you should at least provide some links in the OP?

Cheers Rolf

( addicted to the Perl Programming Language)

  • Comment on Re: Strassen's Algorithm for Matrix Multiplication

Replies are listed 'Best First'.
Re^2: Strassen's Algorithm for Matrix Multiplication
by cormanaz (Deacon) on Apr 13, 2013 at 15:26 UTC
    My bad re missing link.

    That seems to be what they've done in the MCE code example. What I don't get is this argument $tam (used both in perl and C). It says in the C code this has something to do with the "length of the matrix" but a matrix has two dimensions, so I'm not sure what they mean by "length." This is what made me think they were setting up some kind of fixed size test data.

      Strassen's algorithm only works for square matrices of a dimenstion that is a power of two I believe. At least a superficial scan of the Wikipedia article seems to confirm that. It also mentions padding non-square matrices.
        Right you are. That explains it, then. Thanks.