Generalized Mersenne Prime
   HOME

TheInfoList



OR:

In
mathematics Mathematics is a field of study that discovers and organizes methods, Mathematical theory, theories and theorems that are developed and Mathematical proof, proved for the needs of empirical sciences and mathematics itself. There are many ar ...
, a Solinas prime, or generalized Mersenne prime, is a
prime number A prime number (or a prime) is a natural number greater than 1 that is not a Product (mathematics), product of two smaller natural numbers. A natural number greater than 1 that is not prime is called a composite number. For example, 5 is prime ...
that has the form f(2^m), where f(x) is a low- degree
polynomial In mathematics, a polynomial is a Expression (mathematics), mathematical expression consisting of indeterminate (variable), indeterminates (also called variable (mathematics), variables) and coefficients, that involves only the operations of addit ...
with small
integer An integer is the number zero (0), a positive natural number (1, 2, 3, ...), or the negation of a positive natural number (−1, −2, −3, ...). The negations or additive inverses of the positive natural numbers are referred to as negative in ...
coefficient In mathematics, a coefficient is a Factor (arithmetic), multiplicative factor involved in some Summand, term of a polynomial, a series (mathematics), series, or any other type of expression (mathematics), expression. It may be a Dimensionless qu ...
s. These primes allow fast modular reduction algorithms and are widely used in
cryptography Cryptography, or cryptology (from "hidden, secret"; and ''graphein'', "to write", or ''-logy, -logia'', "study", respectively), is the practice and study of techniques for secure communication in the presence of Adversary (cryptography), ...
. They are named after Jerome Solinas. This class of numbers encompasses a few other categories of prime numbers: * Mersenne primes, which have the form 2^k-1, * Crandall or pseudo-Mersenne primes, which have the form 2^k-c for small odd c.


Modular reduction algorithm

Let f(t) = t^d - c_t^ - ... - c_0 be a
monic polynomial In algebra, a monic polynomial is a non-zero univariate polynomial (that is, a polynomial in a single variable) in which the leading coefficient (the nonzero coefficient of highest degree) is equal to 1. That is to say, a monic polynomial is one ...
of degree d with coefficients in \mathbb and suppose that p = f(2^m) is a Solinas prime. Given a number n < p^2 with up to 2md bits, we want to find a number
congruent Congruence may refer to: Mathematics * Congruence (geometry), being the same size and shape * Congruence or congruence relation, in abstract algebra, an equivalence relation on an algebraic structure that is compatible with the structure * In modu ...
to n mod p with only as many bits as p – that is, with at most md bits. First, represent n in base 2^m: :n = \sum_^A_j2^ Next, generate a d-by-d
matrix Matrix (: matrices or matrixes) or MATRIX may refer to: Science and mathematics * Matrix (mathematics), a rectangular array of numbers, symbols or expressions * Matrix (logic), part of a formula in prenex normal form * Matrix (biology), the m ...
X = (X_) by stepping d times the
linear-feedback shift register In computing, a linear-feedback shift register (LFSR) is a shift register whose input bit is a Linear#Boolean functions, linear function of its previous state. The most commonly used linear function of single bits is exclusive-or (XOR). Thus, ...
defined over \mathbb by the polynomial f: starting with the d-integer register 0 , ..., 0 , 1/math>, shift right one position, injecting 0 on the left and adding (component-wise) the output value times the vector _0,...,c_/math> at each step (see for details). Let X_ be the integer in the jth register on the ith step and note that the first row of X is given by (X_) = _0,...,c_/math>. Then if we denote by B = (B_i) the integer vector given by: :(B_0 ... B_) = (A_0 ... A_) + (A_d ... A_)X, it can be easily checked that: :\sum_^B_j2^\equiv\sum_^A_j2^ \mod p. Thus B represents an md-bit integer congruent to n. For judicious choices of f (again, see , this algorithm involves only a relatively small number of additions and subtractions (and no divisions!), so it can be much more efficient than the naive modular reduction algorithm (n - p \cdot (n / p)).


Examples

In 1999,
NIST The National Institute of Standards and Technology (NIST) is an agency of the United States Department of Commerce whose mission is to promote American innovation and industrial competitiveness. NIST's activities are organized into physical s ...
recommended four Solinas primes as moduli for
elliptic curve cryptography Elliptic-curve cryptography (ECC) is an approach to public-key cryptography based on the algebraic structure of elliptic curves over finite fields. ECC allows smaller keys to provide equivalent security, compared to cryptosystems based on modula ...
: * curve p-192 uses modulus 2^ - 2^ - 1 * curve p-224 uses modulus 2^ - 2^ + 1 * curve p-256 uses modulus 2^ - 2^ + 2^ + 2^ -1 * curve p-384 uses modulus 2^ - 2^ - 2^ + 2^ - 1. A newer
Curve448 In cryptography, Curve448 or Curve448-Goldilocks is an elliptic curve potentially offering 224 bits of security and designed for use with the elliptic-curve Diffie–Hellman (ECDH) key agreement scheme. History Developed by Mike Hamburg of Rambus ...
uses modulus 2^ - 2^ - 1.


See also

*
Mersenne prime In mathematics, a Mersenne prime is a prime number that is one less than a power of two. That is, it is a prime number of the form for some integer . They are named after Marin Mersenne, a French Minim friar, who studied them in the early 1 ...


References

{{Prime number classes, state=collapsed Classes of prime numbers Eponymous numbers in mathematics fr:Nombre de Mersenne premier#Généralisations