1 / 18

Fast Sparse Matrix Multiplication

Fast Sparse Matrix Multiplication. Raphael Yuster Haifa University (Oranim) Uri Zwick Tel Aviv University ESA 2004. Matrix multiplication. j. i. =. . Matrix multiplication. Sparse Matrix Multiplication. =. . n - number of rows and columns m - number of non-zero elements.

neylan
Download Presentation

Fast Sparse Matrix Multiplication

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Fast SparseMatrix Multiplication Raphael YusterHaifa University (Oranim) Uri ZwickTel Aviv University ESA 2004

  2. Matrix multiplication j i = 

  3. Matrix multiplication

  4. Sparse Matrix Multiplication =  n - number of rows and columnsm - number of non-zero elements The distribution of the non-zeroelements in the matrices is arbitrary!

  5. Sparse Matrix Multiplication j k k =  Each element of B is multiplied by at most n elements from A. Complexity:mn

  6. Matrix multiplication Can we do something better?

  7. Comparison mn m0.7n1.2+n2  n2.38 Complexity = n r (m=nr)

  8. =  A closer look at the naïve algorithm = 

  9. Complexity of the naïve algorithm Complexity = where Can it really be that bad?

  10. Best case for naïve algorithm Regular case:

  11. Worst case for naïve algorithm

  12. Worst case for naïve algorithm 0 =  0

  13. p n n n =  n p Rectangular Matrix multiplication Coppersmith (1997):Complexity ≤ n1.85p0.54+n2+o(1) For p ≤ n0.29, complexity = n2+o(1) !!!

  14. B1 A2 A1 B2 Complexity: The combined algorithm Fast rectangularmatrix multiplication Naïve sparsematrix multiplication Assume:a1b1 ≥ a2b2 ≥ … ≥ anbn Choose: 0 ≤ p ≤ n Compute:AB = A1B1+ A2B2

  15. Lemma: Analysis of combined algorithm Theorem:There exists a 1≤p≤n for which

  16. Complexity of new algorithm: m0.64n1.46+n2+o(1) Multiplying three sparse matrices   A B C n - number of rows and columnsm - number of non-zero elements

  17. Applications • Computing the square of a sparse graph • Finding short cycles (YZ’04) • Other applications?

  18. Open problems • A faster, more sophisticated, algorithmfor sparse matrix multiplication? • A faster algorithm for multiplying three or more sparse matrices? • An O(m1-n1+) transitive closure algorithm?

More Related