We gratefully acknowledge support from
the Simons Foundation and member institutions.
Full-text links:


Current browse context:


Change to browse by:


References & Citations

DBLP - CS Bibliography


(what is this?)
CiteULike logo BibSonomy logo Mendeley logo del.icio.us logo Digg logo Reddit logo ScienceWISE logo

Computer Science > Data Structures and Algorithms

Title: Speeding up decimal multiplication

Abstract: Decimal multiplication is the task of multiplying two numbers in base $10^N.$ Specifically, we focus on the number-theoretic transform (NTT) family of algorithms. Using only portable techniques, we achieve a 3x-5x speedup over the mpdecimal library. In this paper we describe our implementation and discuss further possible optimizations. We also present a simple cache-efficient algorithm for in-place $2n \times n$ or $n \times 2n$ matrix transposition, the need for which arises in the "six-step algorithm" variation of the matrix Fourier algorithm, and which does not seem to be widely known. Another finding is that use of two prime moduli instead of three makes sense even considering the worst case of increasing the size of the input, and makes for simpler answer recovery.
Subjects: Data Structures and Algorithms (cs.DS)
Cite as: arXiv:2011.11524 [cs.DS]
  (or arXiv:2011.11524v4 [cs.DS] for this version)

Submission history

From: Viktor Krapivensky [view email]
[v1] Mon, 23 Nov 2020 16:35:53 GMT (40kb)
[v2] Wed, 25 Nov 2020 06:06:19 GMT (40kb)
[v3] Fri, 27 Nov 2020 09:46:27 GMT (40kb)
[v4] Wed, 9 Dec 2020 20:26:35 GMT (40kb)

Link back to: arXiv, form interface, contact.