← LibraryThe Jacobi SymbolEngineering · MathematicsLesson 139/385← PrevNext →
ArticlePublished 7 Aug 20263 min readBy Kevin Jogin

Engineering  /  Mathematics  — Quadratic Residues

The Jacobi Symbol

The Jacobi symbol as the multiplicative extension of the Legendre symbol to odd composite moduli, and what it does and does not tell you.

Page KV-MATH-0411Reading time 3 minReviewed 2026-08-07Author Kevin Jogin

Executive summary

The Jacobi symbol extends the Legendre symbol to odd composite moduli by multiplying the Legendre symbols of the prime factors. It inherits multiplicativity and reciprocity.

What it loses is the connection to residuosity: a Jacobi symbol of plus one does not mean the argument is a square, and that failure is exploited cryptographically.

Learning objectives

  1. Define the Jacobi symbol and state its properties.
  2. Identify precisely what it fails to determine.
  3. Explain its cryptographic significance.

01Definition

Definition

Jacobi symbol

For odd n = p₁^{e₁} ··· pₖ^{eₖ} and integer a,

(a|n) = ∏ᵢ (a|pᵢ)^{eᵢ}, a product of Legendre symbols.

The definition uses the factorisation, but the value is computable without it — this is the central point. Reciprocity and the supplementary laws hold for the Jacobi symbol verbatim, so the Euclid-style algorithm applies directly to composite moduli.

Jacobi symbol properties
PropertyHolds for Jacobi?
Multiplicative in the numeratorYes
Multiplicative in the denominatorYes
ReciprocityYes
Supplementary lawsYes
(a|n) = 1 implies a is a residueNo
(a|n) = −1 implies a is a non-residueYes

02The one-sided implication

The smallest illustration: modulo 15 = 3 · 5, take a = 2. Then (2|3) = −1 and (2|5) = −1, so (2|15) = 1. Yet 2 is not a square modulo 15, since it is a square modulo neither factor.

(2|15) = (2|3)(2|5) = (−1)(−1) = +1,   but 2 is not a QR mod 15

For n = pq the units with Jacobi symbol +1 split evenly into genuine residues and pseudo-residues of this kind. Distinguishing the two halves is the quadratic residuosity problem.

03Cryptographic significance

The gap between computable Jacobi symbol and uncomputable residuosity is unusual and directly useful.

  • Public and private

    Anyone can compute the Jacobi symbol from n alone. Only someone knowing the factorisation can decide residuosity.

  • A hard-core predicate

    Residuosity within the Jacobi-plus-one set is believed hard, giving a bit that is hidden from an adversary but known to the key holder.

  • Encryption schemes

    Goldwasser–Micali encrypts a bit as a random residue or pseudo-residue, with decryption requiring the factorisation.

04Frequently asked questions

Is the Jacobi symbol defined for even moduli?

Not in the standard definition, which requires n odd. The Kronecker symbol extends it further to include even moduli and negative arguments, at the cost of extra case handling.

Why is the Jacobi symbol computable without factoring?

Because reciprocity permits swapping numerator and denominator, and reduction shrinks both. The algorithm never needs to know the factorisation — it only needs the arguments to be odd, which extracting powers of two ensures.

How is a random element with Jacobi symbol +1 generated?

By drawing uniformly and computing the symbol, retrying on −1. Half of all units qualify, so the expected cost is two draws.

Sources and method

Structural reference: Victor Shoup, A Computational Introduction to Number Theory and Algebra, Version 1, Cambridge University Press, 2005 — book pages 287-289.

This page carries the durable method layer only: definitions, constructions, algorithms, complexity results and selection criteria, authored originally for KEVOS. No text is transcribed or paraphrased from the source, and no numeric tables or benchmark data are reproduced — these are routed to live authoritative sources instead.

Author: Kevin Jogin. Last reviewed 2026-08-07.

Continue learning

The Law of Quadratic ReciprocityArticle · MathematicsNEXT LESSON →Computing the Jacobi SymbolArticle · MathematicsThe Legendre SymbolArticle · MathematicsTesting Quadratic Residuosity: Prime ModulusArticle · Mathematics