It is widely known that the lower bound for the algorithmic complexity of square matrix multiplication resorts to at least $n^2$ arithmetic operations. The justification builds upon the following reasoning: given that there are $2 n^2$ numbers in the input matrices, any algorithm necessarily must operate on each at least once. In this paper, we show that this is not necessarily the case for certain instances of the problem, for instance matrices with natural number entries. We present an algorithm performing a single multiplication and $(n - 1)$ sums, therefore using n arithmetic operations. The ingenuity of the approach relies on encoding the original $2n^2$ elements as two numbers of much greater magnitude. Thus, though processing each of the inputs at least once, it relies on a lower count of arithmetic operations. In the computational model used to analyze this problem, such encoding operation is not available, thus it is not clear this work affects the currently accepted complexity results for matrix multiplication, but the new algorithm complexity (when taking into account the encodings) is $3n^2 + 2n - 1$ operations. In addition, given the exponential increase in multiplication operands magnitude, its practical usage is constrained to certain instances of the problem. Nonetheless, this work presents a novel mathematically inspired algorithm while pointing towards an alternative research path, which opens the possibility of novel algorithms and a taxonomy of matrix multiplications and associated complexities.
翻译:广泛认为,方阵乘法算法复杂度的下界至少需要$n^2$次算术运算。这一论断基于以下推理:由于输入矩阵中共有$2n^2$个数,任何算法必然至少对每个数进行一次操作。本文表明,对于该问题的某些实例(例如元素为自然数的矩阵),情况并非必然如此。我们提出了一种仅执行一次乘法和$(n-1)$次加法、从而使用n次算术运算的算法。该方法的巧妙之处在于将原始的$2n^2$个元素编码为两个数量级更大的数。因此,尽管算法至少处理了每个输入一次,但它依赖的算术运算次数更少。在用于分析该问题的计算模型中,这种编码操作并不可用,因此本工作是否影响当前公认的矩阵乘法复杂度结论尚不明确,但新算法的复杂度(若考虑编码操作)为$3n^2 + 2n - 1$次运算。此外,由于乘法操作数数量级呈指数级增长,其实用性仅限于该问题的某些实例。尽管如此,本工作提出了一种新颖的基于数学的算法,同时指出了一条替代研究路径,这为新型算法以及矩阵乘法及其相关复杂度的分类开辟了可能性。