paper

On Updating and Querying Submatrices

arXiv:2010.13180

Abstract

In this paper, we study the -dimensional update-query problem. We provide lower bounds on update and query running times, assuming a long-standing conjecture on min-plus matrix multiplication, as well as algorithms that are close to the lower bounds. Given a -dimensional matrix, an \textit{update} changes each element in a given submatrix from to , where is a given constant. A \textit{query} returns the of all elements in a given submatrix. We study the cases where and are both commutative and associative binary operators. When , updates and queries can be performed in worst-case time for many by using a segment tree with lazy propagation. However, when , similar techniques usually cannot be generalized. We show that if min-plus matrix multiplication cannot be computed in time for any (which is widely believed to be the case), then for , either updates or queries cannot both run in time for any constant , or preprocessing cannot run in polynomial time. Finally, we show a special case where lazy propagation can be generalized for and where updates and queries can run in worst-case time. We present an algorithm that meets this running time and is simpler than similar algorithms of previous works.

On Updating and Querying Submatrices · wovepaper