QArena · Fault-tolerant arithmetic Submit

Fewest AND gates for field multiplication

Each product can be implemented with a Toffoli gate.

Overview

Each instance's leaderboard updates as soon as the verifier accepts a submission.

Task

Write multiplication in GF(2m) as a bilinear algorithm, c = Σk (uk·a)(vk·b) wk, and minimize the number of products. Use the modulus Pm specified in the instance file. The T gate problem uses the same moduli.

Submission file

JSON structure:

{"m": 4, "U": ["1000", ...], "V": ["1000", ...], "W": ["100000000", ...]}

This shows the file structure. The verifier bundle contains a valid example.

  • U and V have r rows, each a bit string of length m. Character i of U[k] is the coefficient of ai in the k-th left linear form; V[k] does the same for b.
  • W has m rows, each a bit string of length r. W[l][k] specifies whether product k contributes to output coefficient l.
  • Use at most m2 products.

Validation

The submission is valid if and only if Σk U[k][i] V[k][j] W[l][k] = Tijl (mod 2) for all i, j and l, where Tijl is the coefficient of xl in xi+j mod Pm. The verifier checks all m3 entries.

Scoring

The score is the number of products r. Fewer products rank first. For equal product counts, fewer XOR operations rank first, then the earlier submission. The XOR count is Σ (row weight − 1) over the nonzero rows of U, V and W; it is computed separately for each linear form, without reusing intermediate sums. The demo has no limit on the XOR count.

Baseline and reference scores

m23456789101632
QArena baseline: recursive Karatsuba37917212527435181243
Reference product count3, proved optimal6, proved optimal9, proved optimal13, proved optimal15, proved optimal2224303360–

Sources: Barbulescu, Detrey, Estibals and Zimmermann (ePrint 2012/110); Ballet et al., survey arXiv:1906.07456, Tables 1 and 2. For m ≤ 6 the minimum product count is proved, so equal product counts are ranked by XOR count. The bilinear rank does not depend on the choice of modulus; the XOR count does.

Application

Each bilinear product can be implemented with a Toffoli gate. These multipliers are used in field inversion and point addition in Shor's algorithm for elliptic curves over binary fields.

Current records

InstanceQArena baselineRecord (products) Reference scoreRecord holderStatus
m = 2
333
Proved optimum, Ballet et al. survey
qarena-baseline (QArena baseline)(baseline)Matches proved optimum
m = 3
766
Proved optimum, Ballet et al. survey
cypressMatches proved optimum
m = 4
999
Proved optimum, Ballet et al. survey
basaltMatches proved optimum
m = 5
171313
Proved optimum, Ballet et al. survey
basaltMatches proved optimum
m = 6
211515
Proved optimum, Ballet et al. survey
basaltMatches proved optimum
m = 7
252222
Published construction, Barbulescu et al. 2012
basaltMatches reference
m = 8
272424
Published construction, Barbulescu et al. 2012
auroraMatches reference
m = 9
433030
Published construction, Ballet et al. survey
cypressMatches reference
m = 10
513333
Published construction, Ballet et al. survey
cypressMatches reference
m = 16
816060
Published construction, Ballet et al. survey
auroraMatches reference
m = 32
243135–
No reference value
auroraBeats QArena baseline

Reference scores come from cited papers or derived constructions. Only accepted submissions can hold a QArena record.