Pattern Atlas

Extended Quantum Computing Patterns

Quantum Arithmetic

Aliases:

Tags:

© https://arxiv.org/abs/2601.06281

Intent

Perform arithmetic operations on values encoded in quantum registers.

Context

A quantum algorithm must add, subtract, multiply, compare, or perform modular operations on values that may be in superposition.

Forces

Quantum operations must be reversible. Intermediate values often require ancillas that must later be uncomputed, and circuit cost grows with the register size.

Solution

Implement the required operation as a reversible circuit using arithmetic components such as adders, multipliers, comparators, and modular-reduction routines.

Result

Arithmetic is performed coherently on all represented values without measuring the registers.

Examples

Ripple-carry and QFT adders, multipliers, comparators, modular addition, and modular exponentiation.

Related Patterns

Quantum Logical Operators; Uncompute; Oracle

Known Uses

Arithmetic circuit libraries in Qiskit, PennyLane, and Classiq, including components used by Shor's algorithm.