Questions tagged [matrix-multiplication]

36 questions
26
votes
2 answers

What is the intuition behind Strassen's Algorithm?

I came across Strassen's algorithm for matrix multiplication, which has time complexity $O(n^{2.81})$, significantly better than the naive $O(n^3)$. Of course, there have been several other improvements in matrix multiplication since Strassen, but…
6
votes
3 answers

Are there absolute reasons to prefer row/column-major memory ordering?

I've heard it said that "Fortran uses column-major ordering because it's faster" but I'm not sure that's true. Certainly, matching column-major data to a column-major implementation will outperform a mixed setup, but I'm curious if there's any…
rayhem
  • 173
  • 6
5
votes
2 answers

Best-known complexity for $l \times m$ by $m \times n$ matrix multiplication?

I know that the fastest known algorithm for multiplying two $m \times m$ matrices runs in time $m^{\omega}$, where currently we have $\omega = 2.3728596$ due to Virginia Williams's latest result (see here and here). But I'm not sure how this…
Caleb Stanford
  • 7,298
  • 2
  • 29
  • 50
5
votes
1 answer

Is there a polynomial sized arithmetic formula for iterated matrix multiplication?

I found an article on Catalytic space which describes how additional memory (which must be returned to it's arbitrary, initial state) can be useful for computation. There's also an expository follow up with some more details. In particular, they…
shimao
  • 213
  • 1
  • 5
4
votes
0 answers

What's the fastest known non-galactic algorithm for matrix multiplication of large matrices

"A galactic algorithm is one that outperforms any other algorithm for problems that are sufficiently large, but where "sufficiently large" is so big that the algorithm is never used in practice." Strassen algorithm works in $O(n^{2.8074})$. There is…
3
votes
1 answer

Usage of matrix multiplication for distance products

This is more of a validation question, for the current best known results. On one hand, we have classical matrix multiplication. Its running time is denoted as $n^\omega$. On the other, we have distance products, where an operation similar to matrix…
3
votes
0 answers

fast multiplication of power of a matrix by a vector

I'm interested in computing of the product $M^n v$, where $M$ is an $m\times m$ matrix (over a semiring) and $v$ is column-vector, with the smallest number of multiplications in the underlying semiring and in the regime of $n=\Theta(m)$. If we first…
Max Alekseyev
  • 211
  • 1
  • 7
3
votes
0 answers

Computing a series of matrix power - matrix products

Assuming we have two dense matrices $A \in \mathbb{R}^{m\times m}, B \in \mathbb{R}^{m\times n}$, is there a smart way to compute all entries of the series $A^1 B, A^2 B, A^3 B, \dots, A^k B$ up to some k? In general the matrices are arbitrary, but…
3
votes
1 answer

Calculate boolean matrix multiplication (BMM) using transitive closure

Let us say I am given an algorithm that calculates the transitive closure of a given graph $G = \{ V, E \}$. How can I use this algorithm in order to perform the Boolean Matrix Multiplication of two matrices $X$ and $Y$? I know that in order to…
2
votes
1 answer

Classical matrix multiplication via Min-Plus matrix multiplication

Just a thought I had in mind. I can use classical matrix multiplication to compute min-plus matrix multiplication. Generally speaking, considering $(n+1)^{a_{i,j}}$ for each entry and then taking the smallest value. But what about the other way…
2
votes
0 answers

Has Triangle Finding ever been faster than Matrix Multiplication?

The Triangle Finding problem (TF) in Graph Theory was shown by Itai and Rodeh in 1977 [1] to be solvable as fast$^1$ as Boolean Matrix Multiplication (BMM, Matrix Multiplication over $\{0, 1\}$ with AND for $\times$ and OR for $+$). It seems to be…
2
votes
3 answers

In Strassen's algorithm, why does padding the matrices with zeros not affect the asymptopic complexity?

In Strassen's algorithm, why does padding the matrices with zeros, in order to multiply matrices that are not powers of 2, not affect the asymptopic complexity? Hi, I was reading this question but I do not follow Yuval Filmus's answer completely. He…
1
vote
1 answer

Algorithm for solving linear equations if interested only in the first component

If I want to solve $\mathbf A \mathbf x = \mathbf b$, but I am only interested in the value of $x_1$, what algorithm should I use, and will it always be strictly more efficient than solving for all of $\mathbf x$? This can be useful in finding the…
1
vote
1 answer

Compute matrix inversion / multiplication using a black box

Suppose you're given a black box $A$, and you're told $A$ can invert a matrix (assuming the matrix is invertible) $M$ in $O(T_A)$. You're also given a black box $B$, and you're told $B$ can multiply two matrices $X$ and $Y$ in $O(T_B)$. There are…
ErroR
  • 1,954
  • 6
  • 22
1
vote
0 answers

Matrix multiplication of natural numbers

I know matrix multiplication of matrices with real numbers is bounded by $ \Omega (n^2 log(n))$, but what about if all numbers are natural? Can we use the same methods to get a lower bound for this case and how should I do this? Also, what is the…
Roger
  • 31
  • 3
1
2 3