B-smooth integer 2026-10-14
For a specified finite prime factor base , a nonzero integer is -smooth if every prime dividing its absolute value belongs to . Negative residues are handled by including the sign in their exponent vectors. This notation refers to a finite prime set, rather than the alternative convention in which a numerical smoothness bound is called .
Congruence of squares 2026-10-14
A congruence of squares says that two integers have the same square modulo a positive integer . Factoring their difference of squares givesA useful integer factorization results when or is a proper divisor of . Divisibility of a product does not generally force divisibility of either factor by all of : different prime factors of can divide different parts of that product.
For , . ThereforeThus . The prime seven divides the difference, while eleven divides the sum. These computations already give a complete prime factorization because seven and eleven are prime numbers.
The Chinese remainder theorem explains the hidden sign choices. The four congruence classes solving have representatives . Modulo seven each is or ; modulo eleven each is or . Two independent sign choices produce four roots. The inputs thirteen and twenty agree modulo seven and disagree by sign modulo eleven, allowing their sum and difference to separate the two prime factors.
For distinct odd prime numbers , and , a solution with and modulo yields both proper factors by the two greatest common divisors. For a general composite integer, a proper divisor need not itself be prime; further factoring can remain. If or in the coprime case, the two calculations return and one instead. A factor base helps generate relations, but does not ensure every resulting relation is useful.
For historical context, Pomerance describes Kraitchik's 1920s enhancement of the difference-of-squares approach associated with Fermat: seek a difference that is a multiple of , rather than exactly . His account also notes antecedents in Gauss and Seelhoff, so this is not an attribution of the whole idea to a single inventor. [ref]
https://math.dartmouth.edu/~carlp/PDF/paper109.pdf. Carl Pomerance, A Tale of Two Sieves (1996), pp. 1474–1475: difference-of-squares and congruent squares
. Exponent vector 2026-10-14
Relative to an ordered factor base , a positive integer has exponent vector . Multiplication of such integers adds their exponent vectors. Reducing every coordinate modulo two gives the parity vector used to find congruences of squares. The ordering and any sign coordinate must be used consistently across all rows.
Factor base Created 2026-10-14 Updated 2026-10-20
A factor base is a finite set of small prime numbers over which selected auxiliary integers are completely factored. Some methods also record a sign coordinate for , which is not a prime number. A positive integer supported entirely on the chosen factor base gives an exponent vector; reducing that vector modulo two records which prime exponents are odd integers. The product is a square of a number precisely when every prime exponent is an even integer.
For the original toy , use factor base and the two relationsThe residues have exponent vectors and in the order . Adding the two vectors modulo two gives , so multiplying the residues gives . Consequentlyand and . Neither individual residue was a square; combining the relations made all exponents even.
In a larger collection, choose relations with positive residues . If a nonempty selection has an even sum in every exponent coordinate, setThen . Finding such a selection is a linear dependence problem over the finite field : the indicator vector of the chosen relations belongs to the kernel of a linear map given by the parity matrix. This is why a problem about prime factors recruits linear algebra. The final congruence of squares may still be trivial, so another selection can be needed. [ref]
https://crypto.stanford.edu/pbc/notes/crypto/factoring.html. Ben Lynn, Factoring and Discrete Logarithms, Dixon's Algorithm: exponent matrix and kernel
.There is a tradeoff: a small factor base gives a smaller parity matrix, but fewer auxiliary integers factor completely over it. A larger factor base accepts more relations but makes the linear algebra larger. Negative auxiliary values need an additional sign coordinate, and a selected product needs even sign parity as well as even prime exponents. Pomerance's account explains this balance and the historical development of combining smooth relations; the toy example omits algorithm-specific sieving and running-time claims. [ref]
https://math.dartmouth.edu/~carlp/PDF/paper109.pdf. Carl Pomerance, A Tale of Two Sieves (1996), pp. 1475–1476: exponent parity, factor bases and signs
. Integer factorization Created 2026-10-13 Updated 2026-10-20
Integer factorization seeks the prime factorization of a positive integer . For , this means identifying its prime factors and their multiplicities; one has the empty prime factorization. Finding one proper divisor is useful progress, but need not finish the job: factor and further until all factors are prime numbers.
For example, is a semiprime, whereas has three prime factors. Primality testing asks whether a proposed integer is prime; it need not return a factor when the answer is no. Trial division is a direct factoring method: try division by small prime numbers until a divisor is found. More elaborate methods obtain a proper divisor through a greatest common divisor of with a specially constructed integer.
The beautiful trick in congruence of squares is that two integers with equal squares modulo can reveal different factors through their sum and difference. In the worked example, gives and . Computing those greatest common divisors uses the Euclidean algorithm; it does not require trying every potential factor. A factor base supplies a systematic way to construct useful equal-square relations. [ref]
https://crypto.stanford.edu/pbc/notes/crypto/factoring.html. Ben Lynn, Factoring and Discrete Logarithms: congruent squares and the linear-algebra step
.This connection is useful in cryptography because recovering the factors of an RSA cryptosystem modulus defeats the factoring assumption behind its construction. That application concerns large, carefully chosen inputs; the small examples here explain the arithmetic mechanism and are not benchmarks or estimates of present cryptographic security.
P-adic valuation Created 2026-09-24 Updated 2026-10-13
For a prime number and a nonzero integer , the P-adic valuation counts the exponent of in its prime factorization:For , it gives , , and . The sign of a nonzero integer does not change these prime exponents. Relative to an ordered factor base, the valuations supply the coordinates of its exponent vector.
The P-adic valuation extends to nonzero rational numbers by . For example, records a factor in the denominator instead of the numerator. Multiplication adds valuations, ; this is the arithmetic reason why adding exponent vectors can make a product a square. In particular, a positive integer is a square of a number precisely when all its prime exponents are even integers, the criterion used by a factor base.
Past exam of the mathematics course of the University of Cambridge 2008 ii Paper 4 11H Solution Created 2026-09-24 Updated 2026-10-14
Put and use conventional convergent indexing starting at zero; the same argument covers all the printed positive indices. The continued fraction complete quotients satisfy , . After the first step they exceed one, while their algebraic conjugates lie in . Indeed , and if with , then .
Write , where are integers and . This form follows by rationalization at each step: and , starting from . The two conjugate inequalities giveso . The standard convergent recursions also giveSubstitute the displayed form of and compare rational and irrational coefficients. This yields and . Therefore the small norm residues from square-root continued fractions obeyThe initial convergent satisfies the same relation with the usual . This avoids the insufficient estimate obtained by merely replacing the convergent error with .
For integer factorization, choose a factor base of small primes for which is a quadratic residue, together with to record negative residues; a prime dividing already supplies a factor. Test the small nonzero integers for being B-numbers. Complete factorization over the base records each prime exponent modulo two. Once enough relations are collected, linear algebra over can choose a nonempty subcollection whose exponent sum is even, including the sign. ThenIf , one of or can yield a nontrivial factor. Relations with a noninvertible may already give a factor through its gcd. The small-residue bound makes smoothness more likely; it does not guarantee that any one dependency gives a nontrivial factor.

