10.12.2012 Views

Prime Numbers

Prime Numbers

Prime Numbers

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

9.5 Large-integer multiplication 493<br />

There is an elegant relation due to Shokrollahi in 1994; see [Buhler et al. 2000],<br />

that gives a congruence for precisely these Bernoulli numbers:<br />

Theorem 9.5.14. Let g be a primitive root of the odd prime p, and set:<br />

<br />

−1 j (g mod p)(g mod p)<br />

cj =<br />

g<br />

p<br />

−j<br />

for j ∈ [0,p− 2]. Then for k ∈ [1, (p − 3)/2] we have<br />

p−2<br />

cjg 2kj ≡ 1 − g 2k B2k<br />

2kg<br />

j=0<br />

(mod p). (9.28)<br />

We see that Shokrollahi’s relation involves a length-(p − 1) DFT, with the<br />

operant field being Fp. One could proceed with an FFT algorithm, except<br />

that there are two problems with that approach. First, the best lengths for<br />

standard FFTs are powers of two; and second, one cannot use floating-point<br />

arithmetic, especially when the prime p is large, unless the precision is extreme<br />

(and somehow guaranteed). But we have the option of performing a DFT<br />

itself via convolution (see Algorithm 9.6.6), so the Shokrollahi procedure for<br />

determining regular primes; indeed, for finding precise irregularity indices of<br />

any prime, can be effected via power-of-two length convolutions. As we shall<br />

see later, there are “symbolic FFT” means to do this, notably in Nussbaumer<br />

convolution, which avoids floating-point arithmetic and so is suitable for pureinteger<br />

convolution. These approaches—Shokrollahi identity and Nussbaumer<br />

convolution—have been used together to determine all regular primes p<<br />

12000000 [Buhler et al. 2000].<br />

9.5.4 Discrete weighted transform (DWT) methods<br />

One variant of DFT-based convolution that has proved important for modern<br />

primality and factorization studies (and when the relevant integers are large,<br />

say in the region of 2 1000000 and beyond) is the discrete weighted transform<br />

(DWT). This transform is defined as follows:<br />

Definition 9.5.15 (Discrete weighted transform (DWT)). Let x be a signal<br />

of length D, and let a be a signal (called the weight signal) of the<br />

same length, with the property that every aj is invertible. Then the discrete<br />

weighted transform X = DWT(x, a) is the signal of elements<br />

D−1 <br />

Xk = (a ∗ x)jg −jk , (9.29)<br />

j=0<br />

with the inverse DWT −1 (X, a) =x given by<br />

xj = 1<br />

D−1 <br />

Xkg<br />

Daj<br />

jk . (9.30)<br />

k=0

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!